From: <ke...@us...> - 2008-09-08 19:21:24
|
Revision: 7567 http://bacula.svn.sourceforge.net/bacula/?rev=7567&view=rev Author: kerns Date: 2008-09-08 19:21:34 +0000 (Mon, 08 Sep 2008) Log Message: ----------- Fix SQL case problem that may cause the failure of DiskToCatalog in bug #1149. Modified Paths: -------------- trunk/bacula/src/cats/sql_get.c trunk/bacula/technotes-2.5 Added Paths: ----------- trunk/bacula/patches/2.4.2-storename.patch trunk/bacula/patches/2.4.2-verifydisk.patch Added: trunk/bacula/patches/2.4.2-storename.patch =================================================================== --- trunk/bacula/patches/2.4.2-storename.patch (rev 0) +++ trunk/bacula/patches/2.4.2-storename.patch 2008-09-08 19:21:34 UTC (rev 7567) @@ -0,0 +1,25 @@ + + This patch fixes a missing storage name problem, which as far + as we can tell never created any problem. + Apply the patch to version 2.4.2 (and previous versions) with: + + cd <bacula-source> + patch -p0 <2.4.2-storename.patch + ./configure <your-options> + make + ... + make install + + +Index: src/dird/msgchan.c +=================================================================== +--- src/dird/msgchan.c (revision 7507) ++++ src/dird/msgchan.c (working copy) +@@ -229,6 +229,7 @@ + bash_spaces(pool_name); + foreach_alist(storage, rstore) { + Dmsg1(100, "Rstore=%s\n", storage->name()); ++ pm_strcpy(store_name, storage->name()); + bash_spaces(store_name); + pm_strcpy(media_type, storage->media_type); + bash_spaces(media_type); Added: trunk/bacula/patches/2.4.2-verifydisk.patch =================================================================== --- trunk/bacula/patches/2.4.2-verifydisk.patch (rev 0) +++ trunk/bacula/patches/2.4.2-verifydisk.patch 2008-09-08 19:21:34 UTC (rev 7567) @@ -0,0 +1,26 @@ + + This patch fixes a case problem in an SQL command, and could potentially + fix the DiskToCatalog problem reported in bug #1149. + Apply the patch to version 2.4.2 (and previous versions) with: + + cd <bacula-source> + patch -p0 <2.4.2-verifydisk.patch + ./configure <your-options> + make + ... + make install + + +Index: src/cats/sql_get.c +=================================================================== +--- src/cats/sql_get.c (revision 7507) ++++ src/cats/sql_get.c (working copy) +@@ -109,7 +109,7 @@ + Mmsg(mdb->cmd, + "SELECT FileId, LStat, MD5 FROM File,Job WHERE " + "File.JobId=Job.JobId AND File.PathId=%s AND " +-"File.FilenameId=%s AND Job.Type='B' AND Job.JobSTATUS='T' AND " ++"File.FilenameId=%s AND Job.Type='B' AND Job.JobStatus='T' AND " + "ClientId=%s ORDER BY StartTime DESC LIMIT 1", + edit_int64(fdbr->PathId, ed1), + edit_int64(fdbr->FilenameId, ed2), Modified: trunk/bacula/src/cats/sql_get.c =================================================================== --- trunk/bacula/src/cats/sql_get.c 2008-09-08 19:21:08 UTC (rev 7566) +++ trunk/bacula/src/cats/sql_get.c 2008-09-08 19:21:34 UTC (rev 7567) @@ -109,7 +109,7 @@ Mmsg(mdb->cmd, "SELECT FileId, LStat, MD5 FROM File,Job WHERE " "File.JobId=Job.JobId AND File.PathId=%s AND " -"File.FilenameId=%s AND Job.Type='B' AND Job.JobSTATUS='T' AND " +"File.FilenameId=%s AND Job.Type='B' AND Job.JobStatus='T' AND " "ClientId=%s ORDER BY StartTime DESC LIMIT 1", edit_int64(fdbr->PathId, ed1), edit_int64(fdbr->FilenameId, ed2), Modified: trunk/bacula/technotes-2.5 =================================================================== --- trunk/bacula/technotes-2.5 2008-09-08 19:21:08 UTC (rev 7566) +++ trunk/bacula/technotes-2.5 2008-09-08 19:21:34 UTC (rev 7567) @@ -62,6 +62,8 @@ General: 08Sep08 +kes Fix SQL case problem that may cause the failure of DiskToCatalog + in bug #1149. kes First cut adding SD plugins. 03Sep08 kes Add Slot if it is non-zero to writing bsr file after a This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |