[Openvas-commits] r6601 - in trunk/openvas-manager: . src
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Mon Feb 1 14:59:24 CET 2010
Author: mattm
Date: 2010-02-01 14:59:23 +0100 (Mon, 01 Feb 2010)
New Revision: 6601
Modified:
trunk/openvas-manager/ChangeLog
trunk/openvas-manager/src/tasks_sql.h
Log:
* src/tasks_sql.h (manage_set_config_nvts): Update family count when
updating cached config info.
Modified: trunk/openvas-manager/ChangeLog
===================================================================
--- trunk/openvas-manager/ChangeLog 2010-02-01 12:41:33 UTC (rev 6600)
+++ trunk/openvas-manager/ChangeLog 2010-02-01 13:59:23 UTC (rev 6601)
@@ -1,5 +1,10 @@
2010-02-01 Matthew Mundell <matthew.mundell at intevation.de>
+ * src/tasks_sql.h (manage_set_config_nvts): Update family count when
+ updating cached config info.
+
+2010-02-01 Matthew Mundell <matthew.mundell at intevation.de>
+
* src/openvasmd.c (handle_sigabrt): Check if already in handler.
* src/tasks_sql.h (manage_set_config_nvts)
Modified: trunk/openvas-manager/src/tasks_sql.h
===================================================================
--- trunk/openvas-manager/src/tasks_sql.h 2010-02-01 12:41:33 UTC (rev 6600)
+++ trunk/openvas-manager/src/tasks_sql.h 2010-02-01 13:59:23 UTC (rev 6601)
@@ -8234,8 +8234,12 @@
/* Update the cached config info. */
- sql ("UPDATE configs SET nvt_count = nvt_count - %i + %i"
+ sql ("UPDATE configs SET family_count = family_count + %i,"
+ " nvt_count = nvt_count - %i + %i"
" WHERE ROWID = %llu;",
+ old_nvt_count == 0
+ ? (new_nvt_count == 0 ? 0 : 1)
+ : (new_nvt_count == 0 ? -1 : 0),
old_nvt_count,
MAX (new_nvt_count, 0),
config);
More information about the Openvas-commits
mailing list