Change how a few pointer are supplied to functions, removes warnings about breaking aliasing rules

darcs-hash:20060326112339-ac50b-eb135567f6a6183e5dbc310c093d2139ecc8fa4b.gz
This commit is contained in:
axel
2006-03-26 21:23:39 +10:00
parent 7fd2ae4ffd
commit 53c95abfb2
2 changed files with 11 additions and 3 deletions

9
env.c
View File

@@ -820,14 +820,19 @@ void env_set( const wchar_t *key,
static int try_remove( env_node_t *n,
const wchar_t *key )
{
const void *old_key_void, *old_val_void;
wchar_t *old_key, *old_val;
if( n == 0 )
return 0;
hash_remove( &n->env,
key,
(const void **)&old_key,
(const void **)&old_val );
&old_key_void,
&old_val_void );
old_key = (wchar_t *)old_key_void;
old_val = (wchar_t *)old_val_void;
if( old_key != 0 )
{
var_entry_t * v = (var_entry_t *)old_val;