diff options
author | Gerald Combs <gerald@wireshark.org> | 2006-03-07 19:17:00 +0000 |
---|---|---|
committer | Gerald Combs <gerald@wireshark.org> | 2006-03-07 19:17:00 +0000 |
commit | c47503fd5fe46783148323d7b3347be1d3c01be2 (patch) | |
tree | b4a7c572181cf913bc760e61d22797965652c950 /conditions.c | |
parent | 432e1233bbed77519fc4199cefc212501fc10c2f (diff) |
Fix Coverity run 12 CID 110: Make sure we don't dereference a NULL pointer.
svn path=/trunk/; revision=17505
Diffstat (limited to 'conditions.c')
-rw-r--r-- | conditions.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/conditions.c b/conditions.c index 939ed260e0..941fbae02b 100644 --- a/conditions.c +++ b/conditions.c @@ -86,9 +86,11 @@ condition* cnd_new(const char* class_id, ...){ void cnd_delete(condition *cnd){ _cnd_class *cls = NULL; - const char* class_id = cnd->class_id; + const char* class_id; /* check for valid pointer */ if(cnd == NULL) return; + + class_id = cnd->class_id; /* check if hash table is already initialized */ _cnd_init(); /* get the condition class */ |