]> git.sur5r.net Git - bacula/bacula/commitdiff
Add more patches
authorKern Sibbald <kern@sibbald.com>
Mon, 22 Oct 2007 10:21:26 +0000 (10:21 +0000)
committerKern Sibbald <kern@sibbald.com>
Mon, 22 Oct 2007 10:21:26 +0000 (10:21 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@5777 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/patches/2.2.5-postgresql-errors.patch [new file with mode: 0644]

diff --git a/bacula/patches/2.2.5-postgresql-errors.patch b/bacula/patches/2.2.5-postgresql-errors.patch
new file mode 100644 (file)
index 0000000..fb52b80
--- /dev/null
@@ -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)))