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

scm-commit@wald.intevation.org scm-commit at wald.intevation.org
Wed Nov 9 20:26:30 CET 2011


Author: mattm
Date: 2011-11-09 20:26:28 +0100 (Wed, 09 Nov 2011)
New Revision: 12081

Modified:
   trunk/openvas-manager/ChangeLog
   trunk/openvas-manager/src/omp.c
Log:
	* src/omp.c (omp_xml_handle_start_element): Compare ultimate flag with "0"
	instead of "ultimate".  This is the intended behaviour, clients would only
	have been affected if they passed "0" explicitly.

Modified: trunk/openvas-manager/ChangeLog
===================================================================
--- trunk/openvas-manager/ChangeLog	2011-11-09 18:32:55 UTC (rev 12080)
+++ trunk/openvas-manager/ChangeLog	2011-11-09 19:26:28 UTC (rev 12081)
@@ -1,5 +1,11 @@
 2011-11-09  Matthew Mundell <matthew.mundell at greenbone.net>
 
+	* src/omp.c (omp_xml_handle_start_element): Compare ultimate flag with "0"
+	instead of "ultimate".  This is the intended behaviour, clients would only
+	have been affected if they passed "0" explicitly.
+
+2011-11-09  Matthew Mundell <matthew.mundell at greenbone.net>
+
 	* src/manage_sql.c (create_tables): Add index results_by_host.
 
 2011-11-08  Matthew Mundell <matthew.mundell at greenbone.net>

Modified: trunk/openvas-manager/src/omp.c
===================================================================
--- trunk/openvas-manager/src/omp.c	2011-11-09 18:32:55 UTC (rev 12080)
+++ trunk/openvas-manager/src/omp.c	2011-11-09 19:26:28 UTC (rev 12081)
@@ -3916,7 +3916,7 @@
                               "agent_id", &delete_agent_data->agent_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_agent_data->ultimate = strcmp (attribute, "ultimate");
+              delete_agent_data->ultimate = strcmp (attribute, "0");
             else
               delete_agent_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_AGENT);
@@ -3928,7 +3928,7 @@
                               "config_id", &delete_config_data->config_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_config_data->ultimate = strcmp (attribute, "ultimate");
+              delete_config_data->ultimate = strcmp (attribute, "0");
             else
               delete_config_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_CONFIG);
@@ -3941,7 +3941,7 @@
                               &delete_escalator_data->escalator_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_escalator_data->ultimate = strcmp (attribute, "ultimate");
+              delete_escalator_data->ultimate = strcmp (attribute, "0");
             else
               delete_escalator_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_ESCALATOR);
@@ -3955,7 +3955,7 @@
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
               delete_lsc_credential_data->ultimate
-               = strcmp (attribute, "ultimate");
+               = strcmp (attribute, "0");
             else
               delete_lsc_credential_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_LSC_CREDENTIAL);
@@ -3986,7 +3986,7 @@
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
               delete_report_format_data->ultimate = strcmp (attribute,
-                                                            "ultimate");
+                                                            "0");
             else
               delete_report_format_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_REPORT_FORMAT);
@@ -3998,7 +3998,7 @@
                               &delete_schedule_data->schedule_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_schedule_data->ultimate = strcmp (attribute, "ultimate");
+              delete_schedule_data->ultimate = strcmp (attribute, "0");
             else
               delete_schedule_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_SCHEDULE);
@@ -4010,7 +4010,7 @@
                               &delete_slave_data->slave_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_slave_data->ultimate = strcmp (attribute, "ultimate");
+              delete_slave_data->ultimate = strcmp (attribute, "0");
             else
               delete_slave_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_SLAVE);
@@ -4022,7 +4022,7 @@
                               &delete_target_data->target_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_target_data->ultimate = strcmp (attribute, "ultimate");
+              delete_target_data->ultimate = strcmp (attribute, "0");
             else
               delete_target_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_TARGET);
@@ -4034,7 +4034,7 @@
                               &delete_task_data->task_id);
             if (find_attribute (attribute_names, attribute_values,
                                 "ultimate", &attribute))
-              delete_task_data->ultimate = strcmp (attribute, "ultimate");
+              delete_task_data->ultimate = strcmp (attribute, "0");
             else
               delete_task_data->ultimate = 0;
             set_client_state (CLIENT_DELETE_TASK);



More information about the Openvas-commits mailing list