diff --git a/utils.c b/utils.c
index ee60743484c85da4d7882add79e90cd98f4c79af..e2ce549eb11d9714169c4b6948fa2574d2ed5b58 100755
--- a/utils.c
+++ b/utils.c
@@ -503,7 +503,7 @@ char *ast_strcasestr(const char *haystack, const char *needle)
 		offset = strstr(upper(haystack, u1, u1len), upper(needle, u2, u2len));
 		if (offset) {
 			/* Return the offset into the original string */
-			return ((char *)((unsigned int)haystack + (unsigned int)(offset - u1)));
+			return ((char *)((unsigned long)haystack + (unsigned long)(offset - u1)));
 		} else {
 			return NULL;
 		}