[Openvas-commits] r10555 - in trunk/openvas-manager: . src

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Wed Mar 16 05:34:22 CET 2011


Author: mattm
Date: 2011-03-16 05:34:20 +0100 (Wed, 16 Mar 2011)
New Revision: 10555

Modified:
   trunk/openvas-manager/ChangeLog
   trunk/openvas-manager/src/omp.c
Log:
	* src/omp.c (omp_xml_handle_end_element): In CLIENT_GET_TASKS account for
	trash tasks in counts.

Modified: trunk/openvas-manager/ChangeLog
===================================================================
--- trunk/openvas-manager/ChangeLog	2011-03-16 04:32:23 UTC (rev 10554)
+++ trunk/openvas-manager/ChangeLog	2011-03-16 04:34:20 UTC (rev 10555)
@@ -1,5 +1,10 @@
 2011-03-16  Matthew Mundell <matthew.mundell at greenbone.net>
 
+	* src/omp.c (omp_xml_handle_end_element): In CLIENT_GET_TASKS account for
+	trash tasks in counts.
+
+2011-03-16  Matthew Mundell <matthew.mundell at greenbone.net>
+
 	* src/manage_sql.c (task_count): Exclude trashcan tasks.
 	(trash_task_count): New function.
 

Modified: trunk/openvas-manager/src/omp.c
===================================================================
--- trunk/openvas-manager/src/omp.c	2011-03-16 04:32:23 UTC (rev 10554)
+++ trunk/openvas-manager/src/omp.c	2011-03-16 04:34:20 UTC (rev 10555)
@@ -14519,7 +14519,10 @@
                                       " status=\"" STATUS_OK "\""
                                       " status_text=\"" STATUS_OK_TEXT "\">");
               response = g_strdup_printf ("<task_count>%u</task_count>",
-                                          task ? 1 : task_count ());
+                                          task ? 1
+                                               : (get_tasks_data->trash
+                                                   ? trash_task_count ()
+                                                   : task_count ()));
               if (send_to_client (response,
                                   write_to_client,
                                   write_to_client_data))



More information about the Openvas-commits mailing list