Author: cieciwa                      Date: Wed Sep 21 09:35:34 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- updated for version 3.3.1.

---- Files affected:
packages/nagios:
   archivelog-timeformat.patch (1.1 -> 1.2) , nagios-cgi-http_charset.patch 
(1.7 -> 1.8) , nagios-cmd-typo.patch (1.1 -> 1.2) , nagios-doc-usermacros.patch 
(1.1 -> 1.2) , nagios-googlemap.patch (1.4 -> 1.5) 

---- Diffs:

================================================================
Index: packages/nagios/archivelog-timeformat.patch
diff -u packages/nagios/archivelog-timeformat.patch:1.1 
packages/nagios/archivelog-timeformat.patch:1.2
--- packages/nagios/archivelog-timeformat.patch:1.1     Sun Dec  5 12:35:54 2010
+++ packages/nagios/archivelog-timeformat.patch Wed Sep 21 11:35:29 2011
@@ -7,20 +7,20 @@
        stat_result = stat(log_file, &log_file_stat);
  
        /* get the archived filename to use */
--      
asprintf(&log_archive,"%s%snagios-%02d-%02d-%d-%02d.log",log_archive_path,(log_archive_path[strlen(log_archive_path)-1]=='/')?"":"/",t->tm_mon+1,t->tm_mday,t->tm_year+1900,t->tm_hour);
+-      asprintf(&log_archive, "%s%snagios-%02d-%02d-%d-%02d.log", 
log_archive_path, (log_archive_path[strlen(log_archive_path)-1] == '/') ? "" : 
"/", t->tm_mon + 1, t->tm_mday, t->tm_year + 1900, t->tm_hour);
 -
-+      
asprintf(&log_archive,"%s%snagios-%04d-%02d-%02d-%02d.log",log_archive_path,(log_archive_path[strlen(log_archive_path)-1]=='/')?"":"/",
 t->tm_year+1900, t->tm_mon+1,t->tm_mday,t->tm_hour); 
++      asprintf(&log_archive," %s%snagios-%04d-%02d-%02d-%02d.log", 
log_archive_path, (log_archive_path[strlen(log_archive_path)-1] == '/') ? "" : 
"/", t->tm_year + 1900, t->tm_mon + 1, t->tm_mday, t->tm_hour); 
        /* rotate the log file */
-       rename_result=my_rename(log_file,log_archive);
+       rename_result = my_rename(log_file, log_archive);
  
 --- nagios-3.2.3/cgi/cgiutils.c~       2010-12-04 21:34:34.000000000 +0200
 +++ nagios-3.2.3/cgi/cgiutils.c        2010-12-04 23:34:28.915968009 +0200
 @@ -1604,7 +1604,7 @@
-       t=localtime(&this_scheduled_log_rotation);
+       t = localtime(&this_scheduled_log_rotation);
  
        /* use the time that the log rotation occurred to figure out the name 
of the log file */
--      
snprintf(buffer,buffer_length,"%snagios-%02d-%02d-%d-%02d.log",log_archive_path,t->tm_mon+1,t->tm_mday,t->tm_year+1900,t->tm_hour);
-+      
snprintf(buffer,buffer_length,"%snagios-%04d-%02d-%02d-%02d.log",log_archive_path,t->tm_year+1900,t->tm_mon+1,t->tm_mday,t->tm_hour);
-       buffer[buffer_length-1]='\x0';
+-      snprintf(buffer, buffer_length, "%snagios-%02d-%02d-%d-%02d.log", 
log_archive_path, t->tm_mon + 1, t->tm_mday, t->tm_year + 1900, t->tm_hour);
++      snprintf(buffer, buffer_length, "%snagios-%04d-%02d-%02d-%02d.log", 
log_archive_path, t->tm_year + 1900, t->tm_mon + 1, t->tm_mday, t->tm_hour);
+       buffer[buffer_length-1] = '\x0';
  
        return;

================================================================
Index: packages/nagios/nagios-cgi-http_charset.patch
diff -u packages/nagios/nagios-cgi-http_charset.patch:1.7 
packages/nagios/nagios-cgi-http_charset.patch:1.8
--- packages/nagios/nagios-cgi-http_charset.patch:1.7   Tue Sep 15 13:48:51 2009
+++ packages/nagios/nagios-cgi-http_charset.patch       Wed Sep 21 11:35:29 2011
@@ -10,12 +10,12 @@
  extern hostgroup *hostgroup_list;
  extern servicegroup *servicegroup_list;
 @@ -1079,9 +1081,9 @@
-       printf("Expires: %s\r\n",date_time);
+       printf("Expires: %s\r\n", date_time);
  
-       if(output_format==HTML_OUTPUT)
+       if(output_format == HTML_OUTPUT)
 -              printf("Content-type: text/html\r\n\r\n");
 +              printf("Content-type: text/html; charset=\"%s\"\r\n\r\n", 
http_charset);
-       else{
+       else {
 -              printf("Content-type: text/plain\r\n\r\n");
 +              printf("Content-type: text/plain; charset=\"%s\"\r\n\r\n", 
http_charset);
                return;
@@ -24,32 +24,32 @@
 --- nagios-3.2.0/cgi/cgiutils.c        2009-09-11 16:14:43.130251761 +0300
 +++ nagios-3.2.0/cgi/cgiutils.c        2009-09-15 14:46:13.332409409 +0300
 @@ -55,6 +55,7 @@
- char            *statuswrl_include=NULL;
+ char            *statuswrl_include = NULL;
  
- char            *illegal_output_chars=NULL;
-+char            *http_charset=NULL;
+ char            *illegal_output_chars = NULL;
++char            *http_charset = NULL;
  
- char            *notes_url_target=NULL;
- char            *action_url_target=NULL;
+ char            *notes_url_target = NULL;
+ char            *action_url_target = NULL;
 @@ -188,6 +189,9 @@
-       host_unreachable_sound=NULL;
-       normal_sound=NULL;
+       host_unreachable_sound = NULL;
+       normal_sound = NULL;
  
 +      my_free(http_charset);
 +      http_charset = strdup(DEFAULT_HTTP_CHARSET);
 +
-       statusmap_background_image=NULL;
-       statuswrl_include=NULL;
+       statusmap_background_image = NULL;
+       color_transparency_index_r = 255;;
  
 @@ -391,6 +395,9 @@
-               else if(!strcmp(var,"illegal_macro_output_chars"))
-                       illegal_output_chars=strdup(val);
+               else if(!strcmp(var, "illegal_macro_output_chars"))
+                       illegal_output_chars = strdup(val);
  
-+              else if(!strcmp(var,"http_charset"))
-+                      http_charset=strdup(val);
++              else if(!strcmp(var, "http_charset"))
++                      http_charset = strdup(val);
 +
-               else if(!strcmp(var,"notes_url_target"))
-                       notes_url_target=strdup(val);
+               else if(!strcmp(var, "notes_url_target"))
+                       notes_url_target = strdup(val);
  
 @@ -1478,6 +1485,9 @@
                                }
@@ -60,17 +60,7 @@
 +                      encoded_html_string[y++]=input[x];
                /* for simplicity, all other chars represented by their numeric 
value */
                else{
-                       if(escape_html_tags==FALSE)
-@@ -1553,6 +1563,9 @@
-               else if(((char)input[x]==(char)' ') || 
((char)input[x]==(char)'-') || ((char)input[x]==(char)'.') || 
((char)input[x]==(char)'_') || ((char)input[x]==(char)':'))
-                       encoded_html_string[y++]=input[x];
- 
-+              /* high bit chars don't get encoded, so we won't be breaking 
utf8 characters */
-+              else if ((unsigned char)input[x] >= 0x7f)
-+                      encoded_html_string[y++]=input[x];
-               /* for simplicity, all other chars represented by their numeric 
value */
-               else{
-                       encoded_html_string[y]='\x0';
+                       if(escape_html_tags == FALSE)
 --- nagios-3.0.3/cgi/cmd.c     2008-05-19 21:42:26.000000000 +0300
 +++ nagios-3.0.3-cgi/cgi/cmd.c 2008-10-11 12:34:44.496658785 +0300
 @@ -39,6 +39,8 @@
@@ -113,8 +103,8 @@
  extern hostgroup *hostgroup_list;
 @@ -293,7 +295,7 @@
        printf("Pragma: no-cache\r\n");
-       printf("Last-Modified: %s\r\n",date_time);
-       printf("Expires: %s\r\n",date_time);
+       printf("Last-Modified: %s\r\n", date_time);
+       printf("Expires: %s\r\n", date_time);
 -      printf("Content-type: text/html\r\n\r\n");
 +      printf("Content-type: text/html; charset=\"%s\"\r\n\r\n", http_charset);
  
@@ -332,12 +322,12 @@
  extern hostgroup *hostgroup_list;
  extern service *service_list;
 @@ -698,9 +700,9 @@
-       printf("Expires: %s\r\n",date_time);
+       printf("Expires: %s\r\n", date_time);
  
-       if(output_format==HTML_OUTPUT)
+       if(output_format == HTML_OUTPUT)
 -              printf("Content-type: text/html\r\n\r\n");
 +              printf("Content-type: text/html; charset=\"%s\"\r\n\r\n", 
http_charset);
-       else{
+       else {
 -              printf("Content-type: text/plain\r\n\r\n");
 +              printf("Content-type: text/plain; charset=\"%s\"\r\n\r\n", 
http_charset);
                return;
@@ -383,8 +373,8 @@
  
                if(embedded==TRUE)
                        return;
---- nagios-3.0.3/include/cgiutils.h.in 2007-11-11 01:34:26.000000000 +0200
-+++ nagios-3.0.3-cgi/include/cgiutils.h.in     2008-10-11 12:34:44.468657170 
+0300
+--- nagios-3.0.3/include/cgiutils.h    2007-11-11 01:34:26.000000000 +0200
++++ nagios-3.0.3-cgi/include/cgiutils.h        2008-10-11 12:34:44.468657170 
+0300
 @@ -422,6 +422,9 @@
  #define LIFO_ERROR_FILE               2
  #define LIFO_ERROR_DATA               3

================================================================
Index: packages/nagios/nagios-cmd-typo.patch
diff -u packages/nagios/nagios-cmd-typo.patch:1.1 
packages/nagios/nagios-cmd-typo.patch:1.2
--- packages/nagios/nagios-cmd-typo.patch:1.1   Sat Oct 11 18:36:49 2008
+++ packages/nagios/nagios-cmd-typo.patch       Wed Sep 21 11:35:29 2011
@@ -3,9 +3,9 @@
 @@ -977,7 +977,7 @@
                        printf("</b></td></tr>\n");
                        }
-               printf("<tr><td 
CLASS='optBoxItem'>Persistent%s:</td><td><b>",(cmd==CMD_ACKNOWLEDGE_SVC_PROBLEM)?"
 Comment":"");
--              printf("<INPUT TYPE='checkbox' NAME='persistent' 
%s",(cmd==CMD_ACKNOWLEDGE_SVC_PROBLEM)?"":"CHECKED");
-+              printf("<INPUT TYPE='checkbox' NAME='persistent' 
%s>",(cmd==CMD_ACKNOWLEDGE_SVC_PROBLEM)?"":"CHECKED");
+               printf("<tr><td CLASS='optBoxItem'>Persistent%s:</td><td><b>", 
(cmd == CMD_ACKNOWLEDGE_SVC_PROBLEM) ? " Comment" : "");
+-              printf("<INPUT TYPE='checkbox' NAME='persistent' %s", (cmd == 
CMD_ACKNOWLEDGE_SVC_PROBLEM) ? "" : "CHECKED");
++              printf("<INPUT TYPE='checkbox' NAME='persistent' %s>", (cmd == 
CMD_ACKNOWLEDGE_SVC_PROBLEM) ? "" : "CHECKED");
                printf("</b></td></tr>\n");
                printf("<tr><td CLASS='optBoxRequiredItem'>Author (Your 
Name):</td><td><b>");
-               printf("<INPUT TYPE='TEXT' NAME='com_author' VALUE='%s' 
%s>",url_encode(comment_author),(lock_author_names==TRUE)?"READONLY 
DISABLED":"");
+               printf("<INPUT TYPE='TEXT' NAME='com_author' VALUE='%s' %s>", 
escape_string(comment_author), (lock_author_names==TRUE) ? "READONLY DISABLED" 
: "");

================================================================
Index: packages/nagios/nagios-doc-usermacros.patch
diff -u packages/nagios/nagios-doc-usermacros.patch:1.1 
packages/nagios/nagios-doc-usermacros.patch:1.2
--- packages/nagios/nagios-doc-usermacros.patch:1.1     Thu Oct  7 15:38:13 2010
+++ packages/nagios/nagios-doc-usermacros.patch Wed Sep 21 11:35:29 2011
@@ -8,17 +8,6 @@
 ---
 Signed-Off-By: Elan Ruusamäe <[email protected]>
 
---- nagios-3.2.3/html/docs/macrolist.html~     2010-08-28 18:20:57.000000000 
+0300
-+++ nagios-3.2.3/html/docs/macrolist.html      2010-10-07 16:31:08.073321978 
+0300
-@@ -3444,7 +3444,7 @@
- 
- <td class="MacroName"><a name="user">$USERn$</a></td>
- 
--<td class="MacroDescription">The <i>n</i>th user-definable macro. User macros 
can be defined in one or more <a href="configmain.html#resource_file">resource 
files</a>. Nagios supports up to 256 user macros ($USER1$ through 
$USER32$).</td>
-+<td class="MacroDescription">The <i>n</i>th user-definable macro. User macros 
can be defined in one or more <a href="configmain.html#resource_file">resource 
files</a>. Nagios supports up to 256 user macros ($USER1$ through 
$USER256$).</td>
- 
- </tr>
- 
 --- nagios-3.2.3/sample-config/resource.cfg.in 2003-09-12 02:57:51.000000000 
+0300
 +++ nagios-3.2.3/sample-config/resource.cfg.in 2010-10-07 16:33:41.616639353 
+0300
 @@ -15,7 +15,7 @@

================================================================
Index: packages/nagios/nagios-googlemap.patch
diff -u packages/nagios/nagios-googlemap.patch:1.4 
packages/nagios/nagios-googlemap.patch:1.5
--- packages/nagios/nagios-googlemap.patch:1.4  Thu Oct 22 18:05:45 2009
+++ packages/nagios/nagios-googlemap.patch      Wed Sep 21 11:35:29 2011
@@ -18,10 +18,10 @@
 -
 +#define LAYOUT_GOOGLEMAP                              7
  
- typedef struct layer_struct{
+ typedef struct layer_struct {
        char *layer_name;
        struct layer_struct *next;
-         }layer;
+       } layer;
  
 +typedef struct location_t {
 +      char* name;
@@ -74,7 +74,7 @@
 +                      write_google_head_code();
  
                printf("</head>\n");
-               
+ 
 +              if (layout_method == LAYOUT_GOOGLEMAP) {
 +                      printf("<body onload='load()' onunload='GUnload()' 
CLASS='statusmap' name='mappage' id='mappage'>\n");
 +              } else 
@@ -85,16 +85,16 @@
                /* right hand column of top row */
                printf("<td align=right valign=top>\n");
  
--              printf("<form method=\"POST\" action=\"%s\">\n",STATUSMAP_CGI);
+-              printf("<form method=\"POST\" action=\"%s\">\n", STATUSMAP_CGI);
 +              printf("<form name=\"layoutform\" method=\"POST\" 
action=\"%s\">\n",STATUSMAP_CGI);
                printf("<table border=0 CLASS='optBox'>\n");
                printf("<tr><td valign=top>\n");
                printf("<input type='hidden' name='host' 
value='%s'>\n",escape_string(host_name));
 @@ -725,6 +751,7 @@
-               printf("<option value=%d 
%s>Circular\n",LAYOUT_CIRCULAR,(layout_method==LAYOUT_CIRCULAR)?"selected":"");
-               printf("<option value=%d %s>Circular (Marked 
Up)\n",LAYOUT_CIRCULAR_MARKUP,(layout_method==LAYOUT_CIRCULAR_MARKUP)?"selected":"");
-               printf("<option value=%d %s>Circular 
(Balloon)\n",LAYOUT_CIRCULAR_BALLOON,(layout_method==LAYOUT_CIRCULAR_BALLOON)?"selected":"");
-+              printf("<option value=%d 
%s>Googlemap\n",LAYOUT_GOOGLEMAP,(layout_method==LAYOUT_GOOGLEMAP)?"selected":"");
+               printf("<option value=%d %s>Circular\n", LAYOUT_CIRCULAR, 
(layout_method == LAYOUT_CIRCULAR) ? "selected" : "");
+               printf("<option value=%d %s>Circular (Marked Up)\n", 
LAYOUT_CIRCULAR_MARKUP, (layout_method == LAYOUT_CIRCULAR_MARKUP) ? "selected" 
: "");
+               printf("<option value=%d %s>Circular (Balloon)\n", 
LAYOUT_CIRCULAR_BALLOON, (layout_method == LAYOUT_CIRCULAR_BALLOON) ? 
"selected" : "");
++              printf("<option value=%d %s>Googlemap\n", LAYOUT_GOOGLEMAP, 
(layout_method == LAYOUT_GOOGLEMAP) ? "selected" : "");
                printf("</select>\n");
                printf("</td>\n");
                printf("<td CLASS='optBoxItem'>\n");
@@ -112,7 +112,7 @@
        draw_background_extras();
 @@ -1563,10 +1602,19 @@
        return;
-         }
+       }
  
 +/* create the googlemap */
 +void google_map(void){
@@ -125,7 +125,7 @@
 +}
  
  /* draws hosts */
- void draw_hosts(void){
+ void draw_hosts(void) {
 +      
        host *temp_host;
        int x1, x2;
@@ -136,9 +136,9 @@
  
 +      if (layout_method == LAYOUT_GOOGLEMAP)
 +              return;
-       
+ 
        /* user didn't supply any coordinates for hosts, so display a warning */
-       if(coordinates_were_specified==FALSE){
+       if(coordinates_were_specified == FALSE) {
 @@ -2241,6 +2291,197 @@
  /************************* MISC FUNCTIONS *************************/
  /******************************************************************/
================================================================

---- CVS-web:
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/archivelog-timeformat.patch?r1=1.1&r2=1.2&f=u
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/nagios-cgi-http_charset.patch?r1=1.7&r2=1.8&f=u
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/nagios-cmd-typo.patch?r1=1.1&r2=1.2&f=u
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/nagios-doc-usermacros.patch?r1=1.1&r2=1.2&f=u
    
http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/nagios/nagios-googlemap.patch?r1=1.4&r2=1.5&f=u

_______________________________________________
pld-cvs-commit mailing list
[email protected]
http://lists.pld-linux.org/mailman/listinfo/pld-cvs-commit

Reply via email to