cpukit/libnetworking/rtems/rtems_dhcp.c: Fix compilation error

Apparently 'free' is defined as a macro which takes two arguments and calls
rtems_bsdnet_free. When fixing #2405 I added a missing 'free' but didn't notice
it was non-standard.

Closes #2410.
This commit is contained in:
Martin Galvan
2015-09-03 15:25:35 -05:00
committed by Joel Sherrill
parent 9e2197d5d7
commit efb798e16e

View File

@@ -405,7 +405,7 @@ process_options (unsigned char *optbuf, int optbufSize)
strncpy (dhcp_hostname, p, len); strncpy (dhcp_hostname, p, len);
} else { /* realloc failed */ } else { /* realloc failed */
printf ("dhcpc: realloc failed (%s:%d)", __FILE__, __LINE__); printf ("dhcpc: realloc failed (%s:%d)", __FILE__, __LINE__);
free (dhcp_hostname); free (dhcp_hostname, 0);
dhcp_hostname = NULL; dhcp_hostname = NULL;
} }
} else { /* dhcp_hostname == NULL */ } else { /* dhcp_hostname == NULL */