--UugvWAfsgieZRqgk
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Just a minor request: IMO it would be nice to make the CGI hostname
search case insensitive, as the attached patch does.
Holger
--
PGP fingerprint: F1F0 9071 8084 A426 DD59 9839 59D3 F3A1 B8B5 D3DE
--UugvWAfsgieZRqgk
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="case-insensitive-search.diff"
Index: status.c
===================================================================
RCS file: /cvsroot/nagios/nagios/cgi/status.c,v
retrieving revision 1.39
diff -u -r1.39 status.c
--- status.c 12 Jun 2005 00:17:55 -0000 1.39
+++ status.c 9 Sep 2005 19:11:06 -0000
@@ -251,7 +251,7 @@
for(temp_host=host_list;temp_host!=NULL;temp_host=temp_host->next){
if(is_authorized_for_host(temp_host,¤t_authdata)==FALSE)
continue;
- if(strstr(temp_host->name,host_name)==temp_host->name){
+ if(!strncasecmp(temp_host->name,host_name,strlen(host_name))){
free(host_name);
host_name=strdup(temp_host->name);
break;
--UugvWAfsgieZRqgk--
This post was automatically imported from historical nagios-devel mailing list archives
Original poster: [email protected]