Merge remote-tracking branch 'origin/topic/jsiwek/coverity'

* origin/topic/jsiwek/coverity:
  Fix uninitialized (or unused) fields.
  Remove logically dead code.
  Remove dead/unfinished code in unary not expr.
  Fix logic for failed DNS TXT lookups.
  A couple null ptr checks.
  Improve return value checking and error handling.
  Remove unused variable assignments, dead code.
  Prevent division/modulo by zero in scripts.
  Fix unintentional always-false condition.
  Fix invalidated iterator usage.
  Fix DNS_Mgr iterator mismatch.
  Set safe umask when creating script profiler tmp files.
  Fix nesting/indent level whitespace mismatch.
  Add checks to avoid improper negative values use.

BIT-1085 #merged
This commit is contained in:
Robin Sommer 2013-10-02 11:03:29 -07:00
commit d127d8d01d
86 changed files with 517 additions and 242 deletions

View file

@ -16,7 +16,9 @@ using namespace writer;
using threading::Value;
using threading::Field;
SQLite::SQLite(WriterFrontend* frontend) : WriterBackend(frontend)
SQLite::SQLite(WriterFrontend* frontend)
: WriterBackend(frontend),
fields(), num_fields(), db(), st()
{
set_separator.assign(
(const char*) BifConst::LogSQLite::set_separator->Bytes(),
@ -33,9 +35,7 @@ SQLite::SQLite(WriterFrontend* frontend) : WriterBackend(frontend)
BifConst::LogSQLite::empty_field->Len()
);
db = 0;
io = new AsciiFormatter(this, AsciiFormatter::SeparatorInfo(set_separator, unset_field, empty_field));
st = 0;
}
SQLite::~SQLite()