Fix gbproxy_sgsn_by_tlli wraparound

Change-Id: I74ecb655f4d433f7ac14d00d934d237325aab606
Related: SYS#4865, OS#4472
diff --git a/src/gb_proxy_peer.c b/src/gb_proxy_peer.c
index 544eb5f..d2ddfc1 100644
--- a/src/gb_proxy_peer.c
+++ b/src/gb_proxy_peer.c
@@ -534,8 +534,9 @@
 		i++;
 	}
 	// Start again from the beginning
+	i = 0;
 	llist_for_each_entry(sgsn, &cfg->sgsns, list) {
-		if (i > index) {
+		if (i >= index) {
 			break;
 		} else if (sgsn->pool.allow_attach) {
 			return sgsn;