diff --git a/contrib/fulltextindex/fti.c b/contrib/fulltextindex/fti.c
index aa5f066897c5113851ebfd3bf488ca29e6102b01..be4522321d7a2149f0148f46dbcaec394929d970 100644
--- a/contrib/fulltextindex/fti.c
+++ b/contrib/fulltextindex/fti.c
@@ -346,7 +346,7 @@ is_stopword(char *text)
 	char	  **StopLow;		/* for list of stop-words */
 	char	  **StopHigh;
 	char	  **StopMiddle;
-	unsigned int difference;
+	int			difference;
 
 	StopLow = &StopWords[0];	/* initialize stuff for binary search */
 	StopHigh = endof(StopWords);