mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 20:33:08 +00:00
Fix warnings from ICC
darcs-hash:20060329001450-ac50b-9c3fe4f7ca14a077997c421616c07dde03b48c6d.gz
This commit is contained in:
parent
749dad1309
commit
13a51ba4c2
5 changed files with 9 additions and 9 deletions
|
@ -3231,7 +3231,7 @@ static int internal_help( wchar_t *cmd )
|
|||
int builtin_run( wchar_t **argv )
|
||||
{
|
||||
int (*cmd)(wchar_t **argv)=0;
|
||||
cmd = hash_get( &builtin, argv[0] );
|
||||
cmd = (int (*)(wchar_t **))hash_get( &builtin, argv[0] );
|
||||
|
||||
if( argv[1] != 0 && !internal_help(argv[0]) )
|
||||
{
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
Functions used for implementing the ulimit builtin.
|
||||
|
||||
*/
|
||||
#include "config.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <wchar.h>
|
||||
|
@ -12,8 +14,6 @@ Functions used for implementing the ulimit builtin.
|
|||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include "fallback.h"
|
||||
#include "util.h"
|
||||
|
||||
|
|
8
halloc.c
8
halloc.c
|
@ -41,7 +41,7 @@ typedef struct halloc
|
|||
|
||||
static halloc_t *halloc_from_data( void *data )
|
||||
{
|
||||
return (halloc_t *)(data - sizeof( halloc_t ) );
|
||||
return (halloc_t *)(((char *)data) - sizeof( halloc_t ) );
|
||||
}
|
||||
|
||||
static void late_free( void *data)
|
||||
|
@ -83,7 +83,7 @@ void *halloc( void *context, size_t size )
|
|||
{
|
||||
res = parent->scratch;
|
||||
parent->scratch_free -= size;
|
||||
parent->scratch += size;
|
||||
parent->scratch = ((char *)parent->scratch)+size;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -98,7 +98,7 @@ void *halloc( void *context, size_t size )
|
|||
alloc_spill += parent->scratch_free;
|
||||
#endif
|
||||
res = calloc( 1, size + HALLOC_BLOCK_SIZE );
|
||||
parent->scratch = res + size;
|
||||
parent->scratch = (char *)res + size;
|
||||
parent->scratch_free = HALLOC_BLOCK_SIZE;
|
||||
}
|
||||
else
|
||||
|
@ -121,7 +121,7 @@ void *halloc( void *context, size_t size )
|
|||
#ifdef HALLOC_DEBUG
|
||||
parent_count++;
|
||||
#endif
|
||||
me->scratch = ((void *)me) + sizeof(halloc_t) + size;
|
||||
me->scratch = ((char *)me) + sizeof(halloc_t) + size;
|
||||
me->scratch_free = HALLOC_BLOCK_SIZE;
|
||||
|
||||
al_init( &me->children );
|
||||
|
|
|
@ -291,7 +291,7 @@ static void history_save()
|
|||
history_count=0;
|
||||
past_end=1;
|
||||
|
||||
history_load( mode_name );
|
||||
history_load();
|
||||
if( real_pos != 0 )
|
||||
{
|
||||
/*
|
||||
|
|
|
@ -605,7 +605,7 @@ int wildcard_expand( const wchar_t *wc,
|
|||
/*
|
||||
The maximum length of a file element
|
||||
*/
|
||||
size_t ln=MAX_FILE_LENGTH;
|
||||
long ln=MAX_FILE_LENGTH;
|
||||
char * narrow_dir_string = wcs2str( dir_string );
|
||||
|
||||
if( narrow_dir_string )
|
||||
|
|
Loading…
Reference in a new issue