diff options
author | Tomas Chvatal <tchvatal@suse.cz> | 2011-09-23 17:03:04 +0200 |
---|---|---|
committer | Tomas Chvatal <tchvatal@suse.cz> | 2011-09-23 17:23:16 +0200 |
commit | d9f4ffae38b2e50ae4417cf84d6e1d79759941bc (patch) | |
tree | d1cd08b00f0054656c0eaaeb86782a86167fce4f /src/common.c | |
parent | c963e8ab9df2bb5a57585c016808790d8dee5928 (diff) |
Drop useless wg_free and wg_memset functions and cleanup.
The wg_free function does safeguards that are not needed as ansi
C ensures free to behave properly.
The other fixes are based on patch from Lorenzo Cogotti
<miciamail@hotmail.it>.
Diffstat (limited to 'src/common.c')
-rw-r--r-- | src/common.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/src/common.c b/src/common.c index 96394cb..27ba550 100644 --- a/src/common.c +++ b/src/common.c @@ -36,9 +36,6 @@ #include "config.h" #endif #include <stdio.h> -#ifdef HAVE_STDLIB_H -#include <stdlib.h> -#endif #ifdef HAVE_STRINGS_H #include <strings.h> #endif @@ -134,13 +131,6 @@ extern void* wg_realloc( void *ptr, size_t size ) return( result ); } -extern void wg_free( void *mem ) -{ - if ( mem ) { - free(mem); - } -} - extern char *wg_getline( char *line, int size, FILE *fp ) { char *p; |