]> git.ipfire.org Git - people/ms/suricata.git/commitdiff
datasets: fix null pointer deref
authorShivani Bhardwaj <shivanib134@gmail.com>
Mon, 3 Aug 2020 16:43:59 +0000 (22:13 +0530)
committerVictor Julien <victor@inliniac.net>
Tue, 4 Aug 2020 09:23:38 +0000 (11:23 +0200)
src/datasets.c

index 9104ef2e99c7990b3c1a90abdf854988fe36f085..64c6b9c033a80c098ec4cbd651c22a9c46b59f65 100644 (file)
@@ -538,7 +538,7 @@ static bool DatasetIsStatic(const char *save, const char *load)
     /* A set is static if it does not have any dynamic properties like
      * save and/or state defined but has load defined.
      * */
-    if ((load != NULL || strlen(load) > 0) &&
+    if ((load != NULL && strlen(load) > 0) &&
             (save == NULL || strlen(save) == 0)) {
         return true;
     }