SOURCES: 2.2.5-deamon.patch (NEW), 2.2.5-lastwritten.patch (NEW), ...

arekm arekm at pld-linux.org
Sat Oct 27 23:44:56 CEST 2007


Author: arekm                        Date: Sat Oct 27 21:44:56 2007 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- 2.2.5 upstream fixes

---- Files affected:
SOURCES:
   2.2.5-deamon.patch (NONE -> 1.1)  (NEW), 2.2.5-lastwritten.patch (NONE -> 1.1)  (NEW), 2.2.5-nextvol.patch (NONE -> 1.1)  (NEW), 2.2.5-postgresql-errors.patch (NONE -> 1.1)  (NEW), 2.2.5-tray-monitor.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SOURCES/2.2.5-deamon.patch
diff -u /dev/null SOURCES/2.2.5-deamon.patch:1.1
--- /dev/null	Sat Oct 27 23:44:56 2007
+++ SOURCES/2.2.5-deamon.patch	Sat Oct 27 23:44:50 2007
@@ -0,0 +1,40 @@
+
+ This patch fixes the default behavior of a non-DEVELOPER version of Bacula
+ to close STDIN, STDOUT, and STDERR so that an ssh that starts bacula
+ will not hang.  It also fixes a crash in bat when bat is executed and
+ cannot connect to the Director (e.g. it is not running).
+ This patch fixes bugs #991 and #993.
+
+ Apply this fix to Bacula version 2.2.5 with:
+
+ cd <bacula-source>
+ patch -p0 <2.2.5-daemon.patch
+ ./configure (your options)
+ make
+ ...
+ make install
+
+
+Index: src/lib/message.c
+===================================================================
+--- src/lib/message.c	(revision 5744)
++++ src/lib/message.c	(working copy)
+@@ -52,7 +52,8 @@
+  */
+ const char *working_directory = NULL;       /* working directory path stored here */
+ int verbose = 0;                      /* increase User messages */
+-int debug_level = 1;                  /* debug level */
++/* Keep debug level set to zero by default */
++int debug_level = 0;                  /* debug level */
+ time_t daemon_start_time = 0;         /* Daemon start time */
+ const char *version = VERSION " (" BDATE ")";
+ char my_name[30];                     /* daemon name is stored here */
+@@ -1338,7 +1339,7 @@
+       jcr = get_jcr_from_tsd();
+    }
+    /* If no jcr or dequeuing send to daemon to avoid recursion */
+-   if (!jcr || jcr->dequeuing) {
++   if ((jcr && !jcr->msg_queue) || !jcr || jcr->dequeuing) {
+       /* jcr==NULL => daemon message, safe to send now */
+       Jmsg(jcr, item->type, item->mtime, "%s", item->msg);
+       free(item);

================================================================
Index: SOURCES/2.2.5-lastwritten.patch
diff -u /dev/null SOURCES/2.2.5-lastwritten.patch:1.1
--- /dev/null	Sat Oct 27 23:44:56 2007
+++ SOURCES/2.2.5-lastwritten.patch	Sat Oct 27 23:44:50 2007
@@ -0,0 +1,41 @@
+
+  This bug fixes the LastWritten field which was updated during
+  a restore (or a reading migration)
+  This fixes bug #982
+
+  This patch applies to Bacula version 2.2.5 (and previous versions),
+  and can be applied with the following:
+
+  cd <bacula-source>
+  patch -p0 <2.2.5-lastwritten.patch
+  ./configure (your options)
+  make
+  ...
+  make install
+
+
+
+Index: src/dird/catreq.c
+===================================================================
+--- src/dird/catreq.c	(révision 5789)
++++ src/dird/catreq.c	(copie de travail)
+@@ -266,6 +266,11 @@
+          }
+       }
+       Dmsg2(400, "Update media: BefVolJobs=%u After=%u\n", mr.VolJobs, sdmr.VolJobs);
++      /* Check if the volume has been written by the job, 
++       * and update the LastWritten field if needed */
++      if (mr.VolBlocks != sdmr.VolBlocks) {
++         mr.LastWritten = sdmr.LastWritten;
++      }
+       /* Copy updated values to original media record */
+       mr.VolJobs      = sdmr.VolJobs;
+       mr.VolFiles     = sdmr.VolFiles;
+@@ -274,7 +279,6 @@
+       mr.VolMounts    = sdmr.VolMounts;
+       mr.VolErrors    = sdmr.VolErrors;
+       mr.VolWrites    = sdmr.VolWrites;
+-      mr.LastWritten  = sdmr.LastWritten;
+       mr.Slot         = sdmr.Slot;
+       mr.InChanger    = sdmr.InChanger;
+       mr.VolReadTime  = sdmr.VolReadTime;

================================================================
Index: SOURCES/2.2.5-nextvol.patch
diff -u /dev/null SOURCES/2.2.5-nextvol.patch:1.1
--- /dev/null	Sat Oct 27 23:44:56 2007
+++ SOURCES/2.2.5-nextvol.patch	Sat Oct 27 23:44:51 2007
@@ -0,0 +1,29 @@
+
+  This bug fixes the warning message that prints each time an automatic
+  Volume name is created.  This fixes bug #979
+
+  This patch applies to Bacula version 2.2.5 (not to previous versions),
+  and can be applied with the following:
+
+  cd <bacula-source>
+  patch -p0 <2.2.5-newvol.patch
+  ./configure (your options)
+  make
+  ...
+  make install
+
+
+
+Index: src/dird/newvol.c
+===================================================================
+--- src/dird/newvol.c	(revision 5717)
++++ src/dird/newvol.c	(working copy)
+@@ -124,7 +124,7 @@
+    mr->VolumeName[0] = 0;
+    bstrncpy(name, pr->LabelFormat, sizeof(name));
+    ctx.value = 0;
+-   Mmsg(query, "SELECT MAX(MediaId) FROM Media,POOL WHERE Pool.PoolId=%s", 
++   Mmsg(query, "SELECT MAX(MediaId) FROM Media,Pool WHERE Pool.PoolId=%s", 
+         edit_int64(pr->PoolId, ed1));
+    if (!db_sql_query(jcr->db, query.c_str(), db_int64_handler, (void *)&ctx)) {
+       Jmsg(jcr, M_WARNING, 0, _("SQL failed, but ignored. ERR=%s\n"), db_strerror(jcr->db));

================================================================
Index: SOURCES/2.2.5-postgresql-errors.patch
diff -u /dev/null SOURCES/2.2.5-postgresql-errors.patch:1.1
--- /dev/null	Sat Oct 27 23:44:56 2007
+++ SOURCES/2.2.5-postgresql-errors.patch	Sat Oct 27 23:44:51 2007
@@ -0,0 +1,28 @@
+  After a sql error, the error message that is printed 
+  is incorrect and does not include the postgresql error message.  
+  It fixes #989
+
+  This patch applies to Bacula version 2.2.5 (and previous versions),
+  and can be applied with the following:
+
+  cd <bacula-source>
+  patch -p0 <2.2.5-postgresql-errors.patch
+  ./configure (your options)
+  make
+  ...
+  make install
+
+
+Index: src/cats/cats.h
+===================================================================
+--- src/cats/cats.h	(révision 5763)
++++ src/cats/cats.h	(copie de travail)
+@@ -498,7 +498,7 @@
+ #define sql_fetch_row(x)      my_postgresql_fetch_row(x)
+ #define sql_query(x, y)       my_postgresql_query((x), (y))
+ #define sql_close(x)          PQfinish((x)->db)
+-#define sql_strerror(x)       PQresultErrorMessage((x)->result)
++#define sql_strerror(x)       PQerrorMessage((x)->db)
+ #define sql_num_rows(x)       ((unsigned) PQntuples((x)->result))
+ #define sql_data_seek(x, i)   my_postgresql_data_seek((x), (i))
+ #define sql_affected_rows(x)  ((unsigned) atoi(PQcmdTuples((x)->result)))

================================================================
Index: SOURCES/2.2.5-tray-monitor.patch
diff -u /dev/null SOURCES/2.2.5-tray-monitor.patch:1.1
--- /dev/null	Sat Oct 27 23:44:56 2007
+++ SOURCES/2.2.5-tray-monitor.patch	Sat Oct 27 23:44:51 2007
@@ -0,0 +1,25 @@
+
+ This patch activates the Close button in the tray monitor window.
+ It fixes bug #986.
+
+ Apply it to Bacula version 2.2.5 with:
+
+ cd <bacula-source>
+ patch -p0 <2.2.5-tray-monitor.patch
+ make
+ ...
+ make install
+
+Index: src/tray-monitor/tray-monitor.c
+===================================================================
+--- src/tray-monitor/tray-monitor.c	(revision 5717)
++++ src/tray-monitor/tray-monitor.c	(working copy)
+@@ -478,7 +478,7 @@
+    gtk_box_pack_start(GTK_BOX(hbox), button, TRUE, FALSE, 0);
+ 
+    button = new_image_button("gtk-close", _("Close"));
+-// g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gtk_widget_hide), G_OBJECT(window));
++   g_signal_connect_swapped(G_OBJECT(button), "clicked", G_CALLBACK(gtk_widget_hide), G_OBJECT(window));
+    gtk_box_pack_start(GTK_BOX(hbox), button, TRUE, FALSE, 0);
+ 
+    gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
================================================================


More information about the pld-cvs-commit mailing list