[icinga-checkins] icinga.org: icinga-core/r1.3: classic ui: fix display_name survive reconfiguration and is use instead of host_name in classic ui #1282

git at icinga.org git at icinga.org
Wed Mar 30 13:29:38 CEST 2011


Module: icinga-core
Branch: r1.3
Commit: 09b2716450343e73131ef97c359aa0d0dcddd299
URL:    https://git.icinga.org/?p=icinga-core.git;a=commit;h=09b2716450343e73131ef97c359aa0d0dcddd299

Author: Michael Friedrich <michael.friedrich at univie.ac.at>
Date:   Mon Mar 14 16:24:48 2011 +0100

classic ui: fix display_name survive reconfiguration and is use instead of host_name in classic ui #1282

fixes #1282

---

 Changelog          |    1 +
 xdata/xrddefault.c |   10 ----------
 2 files changed, 1 insertions(+), 10 deletions(-)

diff --git a/Changelog b/Changelog
index 38cc3d0..bf0b23c 100644
--- a/Changelog
+++ b/Changelog
@@ -11,6 +11,7 @@ FIXES
 * classic ui: statusmap.cgi: fixed XSS vulnerability #1281
 * classic ui: Fixing tooltip's in status.cgi, not showing messages with carriage return #1244
 * classic ui: cmd.cgi: acknowledgement multiline comment -> command not being processed #1257
+* classic ui: fix display_name survive reconfiguration and is use instead of host_name in classic ui #1282
 
 
 1.3.0 - 16/02/2011
diff --git a/xdata/xrddefault.c b/xdata/xrddefault.c
index 0c97af3..273348b 100644
--- a/xdata/xrddefault.c
+++ b/xdata/xrddefault.c
@@ -351,7 +351,6 @@ int xrddefault_save_state_information(void){
 
 		fprintf(fp,"host {\n");
 		fprintf(fp,"host_name=%s\n",temp_host->name);
-		fprintf(fp,"display_name=%s\n",temp_host->display_name);
 		fprintf(fp,"modified_attributes=%lu\n",(temp_host->modified_attributes & ~host_attribute_mask));
 		fprintf(fp,"check_command=%s\n",(temp_host->host_check_command==NULL)?"":temp_host->host_check_command);
 		fprintf(fp,"check_period=%s\n",(temp_host->check_period==NULL)?"":temp_host->check_period);
@@ -426,7 +425,6 @@ int xrddefault_save_state_information(void){
 
 		fprintf(fp,"service {\n");
 		fprintf(fp,"host_name=%s\n",temp_service->host_name);
-		fprintf(fp,"display_name=%s\n",temp_service->display_name);
 		fprintf(fp,"service_description=%s\n",temp_service->description);
 		fprintf(fp,"modified_attributes=%lu\n",(temp_service->modified_attributes & ~service_attribute_mask));
 		fprintf(fp,"check_command=%s\n",(temp_service->service_check_command==NULL)?"":temp_service->service_check_command);
@@ -1232,10 +1230,6 @@ int xrddefault_read_retention_file_information(char *retention_file, int overwri
 							temp_host->last_state=atoi(val);
 						else if(!strcmp(var,"last_hard_state"))
 							temp_host->last_hard_state=atoi(val);
-						else if(!strcmp(var,"display_name")){
-							my_free(temp_host->display_name);
-							temp_host->display_name=(char *)strdup(val);
-							}
 						else if(!strcmp(var,"plugin_output")){
 							my_free(temp_host->plugin_output);
 							temp_host->plugin_output=(char *)strdup(val);
@@ -1518,10 +1512,6 @@ int xrddefault_read_retention_file_information(char *retention_file, int overwri
 							temp_service->last_state=atoi(val);
 						else if(!strcmp(var,"last_hard_state"))
 							temp_service->last_hard_state=atoi(val);
-						else if(!strcmp(var,"display_name")){
-							my_free(temp_service->display_name);
-							temp_service->display_name=(char *)strdup(val);
-							}
 						else if(!strcmp(var,"current_attempt"))
 							temp_service->current_attempt=atoi(val);
 						else if(!strcmp(var,"current_event_id"))





More information about the icinga-checkins mailing list