diff options
author | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 2003-03-11 23:14:42 +0000 |
---|---|---|
committer | guy <guy@f5534014-38df-0310-8fa8-9805f1628bb7> | 2003-03-11 23:14:42 +0000 |
commit | 03273d105c06341a0c3992622b7ad620ad262a38 (patch) | |
tree | a4f4d0581fac9cfb2f6ee6e7a9f07f2e601f6f38 /util.c | |
parent | 1e212e098dcfb2bed84f63625529c9dc2c7abab2 (diff) |
When registering a string preference, if the value of the preference is
NULL, convert it to a copy of a null string, otherwise replace it with a
copy of the string, so that we know that the variable for the preference
always points to a string that can be freed.
That also obviates the need to worry about a null-pointer value for a
preference variable when checking to see whether a preference has changed.
When checking for a string preference not being set, check for an empty
string, not a null pointer - the above code turns null pointers into
pointers to empty strings, *and* the GUI code does (and always did!) the
same.
git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@7343 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'util.c')
0 files changed, 0 insertions, 0 deletions