From: Eric Leblond Date: Mon, 14 Dec 2015 14:04:47 +0000 (+0100) Subject: unix-manager: display errors like errors X-Git-Tag: suricata-3.0RC3~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=2002b37e30c12278961ff0369bba5692fb0f4802;p=thirdparty%2Fsuricata.git unix-manager: display errors like errors Not being able to setup the output directory or file is an error so it should be printed as such. --- diff --git a/src/runmode-unix-socket.c b/src/runmode-unix-socket.c index 06a71869d4..46aa3100a6 100644 --- a/src/runmode-unix-socket.c +++ b/src/runmode-unix-socket.c @@ -346,13 +346,15 @@ TmEcode UnixSocketPcapFilesCheck(void *data) unix_manager_file_task_running = 1; this->running = 1; if (ConfSet("pcap-file.file", cfile->filename) != 1) { - SCLogInfo("Can not set working file to '%s'", cfile->filename); + SCLogError(SC_ERR_INVALID_ARGUMENTS, + "Can not set working file to '%s'", cfile->filename); PcapFilesFree(cfile); return TM_ECODE_FAILED; } if (cfile->output_dir) { if (ConfSet("default-log-dir", cfile->output_dir) != 1) { - SCLogInfo("Can not set output dir to '%s'", cfile->output_dir); + SCLogError(SC_ERR_INVALID_ARGUMENTS, + "Can not set output dir to '%s'", cfile->output_dir); PcapFilesFree(cfile); return TM_ECODE_FAILED; } @@ -361,7 +363,8 @@ TmEcode UnixSocketPcapFilesCheck(void *data) char tstr[16] = ""; snprintf(tstr, sizeof(tstr), "%d", cfile->tenant_id); if (ConfSet("pcap-file.tenant-id", tstr) != 1) { - SCLogInfo("Can not set working tenant-id to '%s'", tstr); + SCLogError(SC_ERR_INVALID_ARGUMENTS, + "Can not set working tenant-id to '%s'", tstr); PcapFilesFree(cfile); return TM_ECODE_FAILED; }