From: Victor Julien Date: Fri, 17 Apr 2020 12:58:06 +0000 (+0200) Subject: datasets: remove useless variables X-Git-Tag: suricata-6.0.0-beta1~492 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1d8d03184dd91a33251e6a45f5286b387bfda38e;p=thirdparty%2Fsuricata.git datasets: remove useless variables --- diff --git a/src/datasets.c b/src/datasets.c index f68ed2e441..c18ef449f6 100644 --- a/src/datasets.c +++ b/src/datasets.c @@ -368,7 +368,6 @@ static void DatasetGetPath(const char *in_path, { char path[PATH_MAX]; struct stat st; - int ret; if (PathIsAbsolute(in_path)) { strlcpy(path, in_path, sizeof(path)); @@ -377,7 +376,7 @@ static void DatasetGetPath(const char *in_path, } const char *data_dir = ConfigGetDataDirectory(); - if ((ret = stat(data_dir, &st)) != 0) { + if (stat(data_dir, &st) != 0) { SCLogDebug("data-dir '%s': %s", data_dir, strerror(errno)); return; } @@ -385,7 +384,7 @@ static void DatasetGetPath(const char *in_path, snprintf(path, sizeof(path), "%s/%s", data_dir, in_path); // TODO WINDOWS if (type == TYPE_LOAD) { - if ((ret = stat(path, &st)) != 0) { + if (stat(path, &st) != 0) { SCLogDebug("path %s: %s", path, strerror(errno)); if (!g_system) { snprintf(path, sizeof(path), "%s", in_path);