diff options
author | Russ Dill | 2002-12-11 21:12:45 +0000 |
---|---|---|
committer | Russ Dill | 2002-12-11 21:12:45 +0000 |
commit | 1eb7a17b12a6ee3df8849d00d4ebd2c227ccf1f8 (patch) | |
tree | d7b4fa1a385e1943afdd111d4c708a64cdd5520f /networking/udhcp/dhcpc.c | |
parent | d7e1a6c6ebfeecc1e7ff3982235b6edb84d9a017 (diff) | |
download | busybox-1eb7a17b12a6ee3df8849d00d4ebd2c227ccf1f8.zip busybox-1eb7a17b12a6ee3df8849d00d4ebd2c227ccf1f8.tar.gz |
resync with udhcp cvs
Diffstat (limited to 'networking/udhcp/dhcpc.c')
-rw-r--r-- | networking/udhcp/dhcpc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c index c55ebbb..740daaf 100644 --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c @@ -248,7 +248,7 @@ int main(int argc, char *argv[]) switch (c) { case 'c': len = strlen(optarg) > 255 ? 255 : strlen(optarg); - free(client_config.clientid); + if (client_config.clientid) free(client_config.clientid); client_config.clientid = xmalloc(len + 2); client_config.clientid[OPT_CODE] = DHCP_CLIENT_ID; client_config.clientid[OPT_LEN] = len; @@ -264,7 +264,7 @@ int main(int argc, char *argv[]) case 'h': case 'H': len = strlen(optarg) > 255 ? 255 : strlen(optarg); - free(client_config.hostname); + if (client_config.hostname) free(client_config.hostname); client_config.hostname = xmalloc(len + 2); client_config.hostname[OPT_CODE] = DHCP_HOST_NAME; client_config.hostname[OPT_LEN] = len; |