Ethereal-users: Re: [Ethereal-users] segmentation fault of ethereal in Solaris

Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.

From: Guy Harris <guy@xxxxxxxxxx>
Date: Tue, 11 Mar 2003 14:54:30 -0800
On Tue, Mar 11, 2003 at 03:18:34PM +0100, Blank, Georg wrote:
> #0  0xfec32ea8 in strlen () from /usr/lib/libc.so.1
> #1  0xfec84158 in _doprnt () from /usr/lib/libc.so.1
> #2  0xfec85b28 in fprintf () from /usr/lib/libc.so.1
> #3  0x224870 in write_pref ()
> #4  0xfef67a10 in g_list_foreach () from /opt/SMAWPlus/lib/libglib-1.2.so.0
> #5  0x2248c0 in write_module_prefs ()
> #6  0xfef67a10 in g_list_foreach () from /opt/SMAWPlus/lib/libglib-1.2.so.0
> #7  0x22517c in write_prefs ()
> #8  0x27d704 in main ()

I've checked in a change that causes all string preferences with
null-pointer values to, when registered, get their values set to a null
string instead.  This fixes that problem.

I also changed those dissectors with string preferences that treated a
null pointer as a "not set" indication to use a null *string* as a "not
set" indication, instead - that wouldn't even have worked correctly in
all cases *before* my change, because if you edit the preferences, the
preferences are fetched when you click "OK", and you can't get a null
string pointer from a text entry widget, you only get a string.