Wireshark mailing list archives
Re: strlen() and NULL pointer checks
From: Chris Maynard <chris.maynard () gtech com>
Date: Mon, 16 May 2011 20:47:06 +0000 (UTC)
Jeff Morriss <jeff.morriss.ws@...> writes:
Is there a better way? Or better yet, a proper solution?
Not claiming this is better or proper, just another alternative:
epan/strutil.c:
#include <string.h>
size_t ws_strlen(const char *s)
{
if (s == NULL)
return 0;
return strlen(s);
}
___________________________________________________________________________
Sent via: Wireshark-dev mailing list <wireshark-dev () wireshark org>
Archives: http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
mailto:wireshark-dev-request () wireshark org?subject=unsubscribe
Current thread:
- strlen() and NULL pointer checks Jeff Morriss (May 16)
- Re: strlen() and NULL pointer checks Chris Maynard (May 16)
- Re: strlen() and NULL pointer checks Gerald Combs (May 16)
- Re: strlen() and NULL pointer checks Jeff Morriss (May 16)
- Re: strlen() and NULL pointer checks Jakub Zawadzki (May 16)
- Re: strlen() and NULL pointer checks Jeff Morriss (May 16)
- Re: strlen() and NULL pointer checks Guy Harris (May 16)
- Re: strlen() and NULL pointer checks Jeff Morriss (May 17)
- Re: strlen() and NULL pointer checks Jeff Morriss (May 16)
- Re: strlen() and NULL pointer checks Chris Maynard (May 16)
