diff --git a/expand.c b/expand.c index b1ce99168..4180f5bd6 100644 --- a/expand.c +++ b/expand.c @@ -778,7 +778,7 @@ static int expand_variables( wchar_t *in, array_list_t *out, int last_idx ) stop_pos++; while( 1 ) { - int tmp; + long tmp; while( iswspace(in[stop_pos]) || (in[stop_pos]==INTERNAL_SEPARATOR)) stop_pos++; @@ -814,7 +814,7 @@ static int expand_variables( wchar_t *in, array_list_t *out, int last_idx ) int j; for( j=0; j al_get_count( &var_item_list ) ) { error( SYNTAX_ERROR, diff --git a/fish_pager.c b/fish_pager.c index 2686e6089..285d07601 100644 --- a/fish_pager.c +++ b/fish_pager.c @@ -719,7 +719,8 @@ static void mangle_descriptions( array_list_t *l ) */ static void join_completions( array_list_t *l ) { - int i, in, out; + long i; + int in, out; hash_table_t desc_table; hash_init( &desc_table, &hash_wcs_func, &hash_wcs_cmp ); diff --git a/highlight.c b/highlight.c index d79df23c1..e6dd75612 100644 --- a/highlight.c +++ b/highlight.c @@ -753,10 +753,10 @@ static void highlight_universal_internal( wchar_t * buff, { if( prev_q == *str ) { - int pos1, pos2; + long pos1, pos2; level--; - pos1 = (int)al_pop( &l ); + pos1 = (long)al_pop( &l ); pos2 = str-buff; if( pos1==pos || pos2==pos ) { diff --git a/history.c b/history.c index daf1a18f8..f47d983c4 100644 --- a/history.c +++ b/history.c @@ -482,7 +482,7 @@ static int history_test( const wchar_t *needle, const wchar_t *haystack ) /* return wcsncmp( haystack, needle, wcslen(needle) )==0; */ - return (int)wcsstr( haystack, needle ); + return !!wcsstr( haystack, needle ); } const wchar_t *history_prev_match( const wchar_t *str ) diff --git a/sanity.c b/sanity.c index a20d1f509..7a7040026 100644 --- a/sanity.c +++ b/sanity.c @@ -60,7 +60,7 @@ void validate_pointer( const void *ptr, const wchar_t *err, int null_ok ) Test if the pointer data crosses a segment boundary. */ - if( (0x00000003 & (int)ptr) != 0 ) + if( (0x00000003l & (long)ptr) != 0 ) { debug( 0, _(L"The pointer '%ls' is invalid"), err ); sanity_lose();