[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bacula_1.36.2-2sarge1



Dear Release Team:

    Please find attached the patch containing the differences between
bacula_1.36.2-2 and bacula_1.36.2-2sarge1. Thanks to the inestimable
collaboration of Roberto Lumbreras <rover@debian.org>, it is down to
1310 lines.

    This new version includes all upstream RC fixes and solves a number
of minor bugs and glitches with the packaging itself (so that we release
the best package possible). Additionally, it links against
libmysqlclient14 instead of libmysqlclient10, in order to avoid problems
with MySQL 4.1 servers.
    Unfortunately, it stills carries the old documentation and support
for a deprecated config file syntax( i have kept those away as
instructed by Vorlon), which will undoubtly cause me a few headaches in
the future... it does support the new style config, however, so i expect
that most users will be already using the new one.


Thank you in advance for your time. Go Debian!


Cheers,
    J.L.

diff -Naurp bacula-1.36.2-2/ChangeLog bacula-1.36.2-2sarge1/ChangeLog
--- bacula-1.36.2-2/ChangeLog	2005-02-27 21:53:26.000000000 +0000
+++ bacula-1.36.2-2sarge1/ChangeLog	2005-05-20 09:07:19.000000000 +0000
@@ -1,4 +1,59 @@
 
+Changes to 1.36.2sarge1:
+22Apr05
+- Correct return type of ftello to avoid overflow --
+  thanks to Peter Eriksson.
+13Apr05
+- Fix seg fault if Name directive missing in Job resource.
+12Apr05
+- Fix SuSE autostart routines to use /etc/init.d instead
+  of /etc/rc.d/init.d.
+- Increase index size on File table Name and Path table Path
+  to improve performance.
+- Second fix for not zeroing SD pointers on restarted job.
+- Turn off old style Include/Excludes.
+01Apr05
+- Use fseeko and ftello so that attributes can exceed 4GB
+- Flush console output after every line.
+- Turn off Multiple Connections in catalog resource, which
+  causes corruped databases.  It is silently ignored.
+- Drop support for old style Include/Exclude.  There is a
+  perl script that will convert them.
+- Inhibit trying to reset attributes on a Win32 drive.
+18Mar05 1.36.2-store.patch
+- This patch fails a job if no Storage resource is specified and
+  the job attempts to call the SD.
+18Mar05 1.36.2-reschedule.patch
+- This patch should fix a Segfault bug when a job is rescheduled.
+  The storage pointers were being released when they should not
+  have been.
+17Mar05 1.36.2-restore-speed.patch
+- This patch will fix a subtle bug that was introduced in 1.36.2
+  which causes Bacula to be very slow restoring a few files. This
+  is because it reads completely to the end of the Volume rather
+  than stopping when all the files on the Volume are loaded. The
+  introduction of the bug was caused by a patch that fixed 
+  Bacula truncating tapes after a restore.
+  Note that all source files will be rebuilt during the make.
+16Mar05 1.36.2-console.patch
+- This patch causes the output directed to a file to be
+  flushed after every line. This is a bit overkill, IMO, but
+  a user complained about it.
+15Mar05 1.36.2-netbsd.patch
+- This patch corrects a compile problem because of no statfs() 
+  on NetBSD. The patch was submitted by kardel with bug 258.
+09Mar05 1.36.2-win32-drive.patch
+- This patch will prevent the Win32 FD from printing an error message
+  when it attempts to restore the permissions for a drive (which Win32
+  doesn't permit). The error is harmless in any case.
+04Mar05 1.36.2-level.patch
+- This patch should fix a problem with th %l editing in the 
+  client (FD) where it edited nothing. With this fix, it should
+  edit "since".  
+04Mar05 1.36.2-pool.patch
+- This patch corrects a problem preventing multiple 
+  simultaneous jobs from different pools.
+
 Changes to 1.36.2 released 28Feb05:
 27Feb05
 - Fix pointer to stack variable in Verify jobs.
diff -Naurp bacula-1.36.2-2/autoconf/config.h.in bacula-1.36.2-2sarge1/autoconf/config.h.in
--- bacula-1.36.2-2/autoconf/config.h.in	2005-02-16 10:30:19.000000000 +0000
+++ bacula-1.36.2-2sarge1/autoconf/config.h.in	2005-05-20 09:07:19.000000000 +0000
@@ -266,6 +266,9 @@
 /* Define to 1 if you have the `fork' function. */
 #undef HAVE_FORK
 
+/* Define to 1 if you have the `fseeko' function. */
+#undef HAVE_FSEEKO
+
 /* Define to 1 if you have the `getcwd' function. */
 #undef HAVE_GETCWD
 
diff -Naurp bacula-1.36.2-2/autoconf/configure.in bacula-1.36.2-2sarge1/autoconf/configure.in
--- bacula-1.36.2-2/autoconf/configure.in	2005-02-25 09:47:03.000000000 +0000
+++ bacula-1.36.2-2sarge1/autoconf/configure.in	2005-05-20 09:07:19.000000000 +0000
@@ -1504,7 +1504,7 @@ AC_CHECK_FUNCS(strtoll, [AC_DEFINE(HAVE_
 
 AC_CHECK_FUNCS(chflags) 
 
-AC_CHECK_FUNCS(snprintf vsnprintf gethostid getdomainname)
+AC_CHECK_FUNCS(snprintf vsnprintf gethostid getdomainname fseeko)
 
 dnl# --------------------------------------------------------------------------
 dnl# CHECKING FOR THREAD SAFE FUNCTIONS
diff -Naurp bacula-1.36.2-2/configure bacula-1.36.2-2sarge1/configure
--- bacula-1.36.2-2/configure	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/configure	2005-05-20 09:07:19.000000000 +0000
@@ -17970,7 +17970,8 @@ done
 
 
 
-for ac_func in snprintf vsnprintf gethostid getdomainname
+
+for ac_func in snprintf vsnprintf gethostid getdomainname fseeko
 do
 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
 echo "$as_me:$LINENO: checking for $ac_func" >&5
diff -Naurp bacula-1.36.2-2/debian/bacula-director-mysql.postinst bacula-1.36.2-2sarge1/debian/bacula-director-mysql.postinst
--- bacula-1.36.2-2/debian/bacula-director-mysql.postinst	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/bacula-director-mysql.postinst	2005-05-20 09:07:19.000000000 +0000
@@ -63,11 +63,12 @@ configure)
 	
 	if [ -n "$MYSQL_ROOT_PASSWORD" ] && [ "$MYSQL_ROOT_PASSWORD" != "NONE" ]
 	then
-		MYSQL_PSWD_STRING="-p$MYSQL_ROOT_PASSWORD"
+		MYSQL_PSWD_STRING="-p\"$MYSQL_ROOT_PASSWORD\""
 	fi
 
 	echo -n "Checking DB connectivity..."	
-	if ! $MYSQLADMIN $MYSQL_HOST_STRING -u $MYSQL_ROOT_USER "$MYSQL_PSWD_STRING" ping >/dev/null 2>&1
+	if ! eval $MYSQLADMIN $MYSQL_HOST_STRING -u $MYSQL_ROOT_USER \
+		$MYSQL_PSWD_STRING ping >/dev/null 2>&1
 	then
 		echo -e "\nERROR: Could not connect to MySQL server at $MYSQL_HOST"
 		exit 1
@@ -78,14 +79,14 @@ configure)
 	if [ "$RET" = "true" ]; then
 		# Create DB
 		echo -n "Creating Catalog \"$CATALOG\" ..."
-		$MYSQLADMIN $MYSQL_HOST_STRING -u $MYSQL_ROOT_USER "$MYSQL_PSWD_STRING" \
-		create $CATALOG >/dev/null 2>&1 || true
+		eval $MYSQLADMIN $MYSQL_HOST_STRING -u $MYSQL_ROOT_USER $MYSQL_PSWD_STRING \
+			create $CATALOG >/dev/null 2>&1 || true
 		echo "Ok."
 
 		# Create tables
 		echo -n "Creating tables ..."
-		if ! $MAKE_SQL_TABLES $MYSQL_HOST_STRING \
-			-u $MYSQL_ROOT_USER "$MYSQL_PSWD_STRING" >/dev/null 2>&1
+		if ! eval $MAKE_SQL_TABLES $MYSQL_HOST_STRING \
+			-u $MYSQL_ROOT_USER $MYSQL_PSWD_STRING >/dev/null 2>&1
 		then
 			echo -e "\nERROR: Table creation failed!"
 			exit 1
@@ -112,7 +113,7 @@ configure)
 
 		echo -e "GRANT ALL privileges ON $CATALOG.* TO $MYSQL_USER@$MYSQL_HOST_URI " \
 			"$MYSQL_USER_PSWD_STRING;\nFLUSH PRIVILEGES;" \
-			| $MYSQL -h $MYSQL_HOST -u $MYSQL_ROOT_USER "$MYSQL_PSWD_STRING" mysql
+			| $MYSQL -h $MYSQL_HOST -u $MYSQL_ROOT_USER $MYSQL_PSWD_STRING mysql
 
 	fi # bacula-director-mysql/create_tables == "true"
 
@@ -138,7 +139,7 @@ configure)
 		# patched upgrade script to use additional arguments on connection
 		echo -n "Upgrading Catalog to v8 ..."
 		if ! ${UPGRADE_SQL_DIR}/$UPGRADE_TABLES2 $MYSQL_HOST_STRING \
-                        -u $MYSQL_ROOT_USER "$MYSQL_PSWD_STRING" > $LOGDIR/upgrade.log 2>&1
+                        -u $MYSQL_ROOT_USER $MYSQL_PSWD_STRING > $LOGDIR/upgrade.log 2>&1
 		then
                         echo -e "\nERROR: Catalog upgrading failed! Check $LOGDIR/upgrade.log for details."
                         exit 1
diff -Naurp bacula-1.36.2-2/debian/bacula-doc.doc-base bacula-1.36.2-2sarge1/debian/bacula-doc.doc-base
--- bacula-1.36.2-2/debian/bacula-doc.doc-base	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/bacula-doc.doc-base	2005-05-20 09:07:19.000000000 +0000
@@ -6,7 +6,7 @@ Abstract: This manual describes Bacula's
 Section: Admin/Backup
 
 Format: pdf
-Files: /usr/share/doc/bacula/bacula.pdf
+Files: /usr/share/doc/bacula-doc/bacula.pdf
 
 Format: HTML
 Index: /usr/share/doc/bacula-doc/html-manual/index.html
diff -Naurp bacula-1.36.2-2/debian/changelog bacula-1.36.2-2sarge1/debian/changelog
--- bacula-1.36.2-2/debian/changelog	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/changelog	2005-05-20 09:07:19.000000000 +0000
@@ -1,3 +1,21 @@
+bacula (1.36.2-2sarge1) testing-proposed-updates; urgency=medium
+
+  * Backport fixes from 1.36.3 and solve problems with MySQL 4.1
+
+  * bacula-fd
+    - FD offline crashes (#304531)
+
+  * bacula-director-mysql
+    - Additional robustness in postinst
+    - Link libmysqlclient14, to avoid problems with MySQL 4.1 servers
+    - MySQL client incompatibilities (#305161,#305669)
+
+  * Fix location of 'MTX' in scripts (#308803)
+
+  * Include correct manpages (#306430) and updated FR translation(#309664)
+
+ -- Jose Luis Tallon <jltallon@adv-solutions.net>  Wed, 18 May 2005 22:31:25 +0200
+
 bacula (1.36.2-2) unstable; urgency=low
 
   * bacula-director-pgsql: postinst enhancements by Jamie Ffolliott
diff -Naurp bacula-1.36.2-2/debian/control bacula-1.36.2-2sarge1/debian/control
--- bacula-1.36.2-2/debian/control	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/control	2005-05-20 09:07:19.000000000 +0000
@@ -2,7 +2,7 @@ Source: bacula
 Section: admin
 Priority: optional
 Maintainer: Jose Luis Tallon <jltallon@adv-solutions.net>
-Build-Depends: autotools-dev, debhelper (>= 4.1.68), po-debconf (>= 0.8.2), zlib1g-dev, libreadline-dev, libsqlite-dev, libmysqlclient-dev, postgresql-dev, libwrap0-dev, libgnome2-dev, libgnomeui-dev, libwxgtk2.4-dev, libacl1-dev, libkrb5-dev
+Build-Depends: autotools-dev, debhelper (>= 4.1.68), po-debconf (>= 0.8.2), zlib1g-dev, libreadline-dev, libsqlite-dev, libmysqlclient14-dev, postgresql-dev, libwrap0-dev, libgnome2-dev, libgnomeui-dev, libwxgtk2.4-dev, libacl1-dev, libkrb5-dev
 Standards-Version: 3.6.1
 
 Package: bacula
@@ -170,13 +170,10 @@ Package: bacula-wxconsole
 Architecture: any
 Pre-Depends: debconf (>= 1.4.30)
 Depends: bacula-common (= ${Source-Version}), ${shlibs:Depends}
-Description: Network backup, recovery and verification (Console, Gnome version)
+Description: Network backup, recovery and verification (Console, wxWin version)
  The WX-Console allows the administrator or user to communicate with the
  Bacula Director. It provides a graphical interface to the backup/restore
  operations.
  .
  This GUI interface has been designed to ease restore operations as much as
  possible as compared to the "conventional" console.
- .
- There is a Win32 version of this program available for download from
- Bacula's website: www.bacula.org
diff -Naurp bacula-1.36.2-2/debian/manpages/bls.8 bacula-1.36.2-2sarge1/debian/manpages/bls.8
--- bacula-1.36.2-2/debian/manpages/bls.8	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/manpages/bls.8	2005-05-20 09:07:19.000000000 +0000
@@ -20,8 +20,7 @@
 .SH SYNOPSIS
 .B bls
 .RI [ options ]
-.I input-archive
-.I output-archive
+.I <device\-name>
 .br
 .SH DESCRIPTION
 This manual page documents briefly the
@@ -48,20 +47,35 @@ Specify configuration file.
 .BI \-d\  nn
 Set debug level to \fInn\fP.
 .TP
-.BI \-i\  input
-Specify input Volume names (separated by '|').
+.BI \-e\ <file>
+Specify exclude list file
 .TP
-.BI \-o\  output
-Specify output Volume names (separated by '|').
+.BI \-i\  <file>
+Specify include list file
 .TP
-.BI \-w\  directory
-Specify working directory (default \fI/tmp\fP).
+.BI \-j
+List jobs
+.TP
+.BI \-k
+List blocks
+.TP 
+.I (no \-j or \-k option)
+List saved files
+.TP
+.BI -L
+Dump label
+.TP
+.BI \-p
+Proceed despite errors
+.TP
+.BI \-V\  volumes
+Specify volume names (separated by '|').
 .TP
 .B \-v
 Set verbose mode.
 .SH SEE ALSO
-.BR bls (1),
-.BR bextract (1).
+.BR bscan (8),
+.BR bextract (8).
 .br
 .SH AUTHOR
 This manual page was written by Jose Luis Tallon
diff -Naurp bacula-1.36.2-2/debian/manpages/bscan.8 bacula-1.36.2-2sarge1/debian/manpages/bscan.8
--- bacula-1.36.2-2/debian/manpages/bscan.8	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/manpages/bscan.8	2005-05-20 09:07:19.000000000 +0000
@@ -67,8 +67,8 @@ Specify volume names (separated by '|')
 .BI \-w\  dir
 Specify working directory (default from conf file)
 .SH SEE ALSO
-.BR bls (1),
-.BR bextract (1).
+.BR bls (8),
+.BR bextract (8).
 .br
 .SH AUTHOR
 This manual page was written by Jose Luis Tallon
diff -Naurp bacula-1.36.2-2/debian/patches/05-fix_updatedb8.pgsql.patch bacula-1.36.2-2sarge1/debian/patches/05-fix_updatedb8.pgsql.patch
--- bacula-1.36.2-2/debian/patches/05-fix_updatedb8.pgsql.patch	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/patches/05-fix_updatedb8.pgsql.patch	2005-05-20 09:07:19.000000000 +0000
@@ -20,8 +20,7 @@
 +               echo "The Catalog is already at version 8. Nothing to do!"
 +               exit 0
 +       elif [ "$DB_VER" -ne "7" ]; then
-+               echo "Sorry, this script is designed to update a version 7 datab
-ase"
++               echo "Sorry, this script is designed to update a version 7 database"
 +               echo "and you have a version $DB_VER database."
 +               exit 1
 +       fi
diff -Naurp bacula-1.36.2-2/debian/patches/05-fix_updatedb8.sqlite.patch bacula-1.36.2-2sarge1/debian/patches/05-fix_updatedb8.sqlite.patch
--- bacula-1.36.2-2/debian/patches/05-fix_updatedb8.sqlite.patch	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/patches/05-fix_updatedb8.sqlite.patch	2005-05-20 09:07:19.000000000 +0000
@@ -1,51 +1,11 @@
---- updatedb/update_sqlite_tables_7_to_8.orig	2004-10-18 17:29:00.000000000 +0200
-+++ updatedb/update_sqlite_tables_7_to_8	2004-10-21 13:46:10.000000000 +0200
-@@ -8,10 +8,38 @@
- echo "this script may take several minutes to run."
- echo " "
-
--bindir=/home/kern/bacula/depkgs/sqlite
--cd /home/kern/bacula/working
-+bindir=/usr/bin
-
--$bindir/sqlite $* bacula.db <<END-OF-DATA
-+# The location of your bacula working directory
-+workdir=/var/lib/bacula
-+
-+
-+cd $workdir
-+
-+if [ ! -r bacula.db -o ! -s bacula.db ];then
-+       echo "Sorry, can't find a Bacula DB. Aborting."
-+       exit 1
-+fi
-+
-+DB_VER="`echo "select * from Version;" | $bindir/sqlite bacula.db | tail -1 2>/dev/null`"
-+if [ -n "$DB_VER" ]; then
-+
-+       if [ "$DB_VER" = "8" ]; then
-+               echo "The Catalog is already at version 8. Nothing to do!"
-+               exit 0
-+       elif [ "$DB_VER" -ne "7" ]; then
-+               echo "Sorry, this script is designed to update a version 7 datab
-ase"
-+               echo "and you have a version $DB_VER database."
-+               exit 1
-+       fi
-+
-+else
-+        echo "Sorry, I can't seem to locate a bacula database."
-+        exit 1
-+fi
-+
-+
-+$bindir/sqlite $* bacula.db <<END_OF_DATA
-
- BEGIN TRANSACTION;
- CREATE TEMPORARY TABLE Media_backup (
-@@ -118,4 +146,4 @@
- DELETE FROM Version;
- INSERT INTO Version (VersionId) VALUES (8);
-
--END-OF-DATA
-+END_OF_DATA
+--- updatedb/update_sqlite_tables_7_to_8~	2005-04-25 02:25:26.988552200 +0200
++++ updatedb/update_sqlite_tables_7_to_8	2005-04-25 02:25:26.989552048 +0200
+@@ -21,7 +21,7 @@
+        exit 1
+ fi
+ 
+-DB_VER="`echo "select * from Version;" | $bindir/sqlite bacula.db | tail -1 2>/dev/null`"
++DB_VER="`echo 'select * from Version;' | $bindir/sqlite bacula.db | tail -1 2>/dev/null`"
+ if [ -n "$DB_VER" ]; then
+ 
+        if [ "$DB_VER" = "8" ]; then
diff -Naurp bacula-1.36.2-2/debian/patches/11-fix_updatedb.dan_langille.patch bacula-1.36.2-2sarge1/debian/patches/11-fix_updatedb.dan_langille.patch
--- bacula-1.36.2-2/debian/patches/11-fix_updatedb.dan_langille.patch	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/patches/11-fix_updatedb.dan_langille.patch	1970-01-01 00:00:00.000000000 +0000
@@ -1,34 +0,0 @@
---- work/bacula-1.36.0/src/cats/update_postgresql_tables.in	Wed Oct 20 09:35:22 2004
-+++ /home/dan/update_postgresql_tables.in	Wed Nov 10 19:36:14 2004
-@@ -12,6 +12,8 @@
- if $bindir/psql $* -f - <<END-OF-DATA
- \c bacula
- 
-+begin;
-+
- ALTER TABLE media ADD COLUMN EndFile integer;
- UPDATE media SET EndFile=0;
- ALTER TABLE media ALTER COLUMN EndFile SET NOT NULL;
-@@ -21,11 +23,11 @@
- 
- UPDATE Filename SET Name='' WHERE Name=' ';
- 
--alter table file alter column filenameid rename to filenameid-old;
-+alter table file rename column filenameid to filenameid_old;
- alter table file add column filenameid integer;
--update file set filenameid = filenameid-old;
-+update file set filenameid = filenameid_old;
- alter table file alter column filenameid set not null;
--alter table file drop column filenameid-old;
-+alter table file drop column filenameid_old;
- 
- DELETE FROM Version;
- INSERT INTO Version (VersionId) VALUES (8);
-@@ -41,6 +43,8 @@
-    LastBurn timestamp without time zone not null,
-    primary key (MediaId)
- );
-+
-+commit;
- 
- vacuum;
diff -Naurp bacula-1.36.2-2/debian/patches/fix_scripts.sed bacula-1.36.2-2sarge1/debian/patches/fix_scripts.sed
--- bacula-1.36.2-2/debian/patches/fix_scripts.sed	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/patches/fix_scripts.sed	2005-05-20 09:07:19.000000000 +0000
@@ -1,2 +1 @@
-s~^bindir=@SQL_BINDIR@~bindir=/usr/bin~g
-s~@working_dir@~/var/lib/bacula~
+s~MTX=mtx~MTX=/usr/sbin/mtx~
diff -Naurp bacula-1.36.2-2/debian/patches/fix_sql.sed bacula-1.36.2-2sarge1/debian/patches/fix_sql.sed
--- bacula-1.36.2-2/debian/patches/fix_sql.sed	1970-01-01 00:00:00.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/patches/fix_sql.sed	2005-05-20 09:07:19.000000000 +0000
@@ -0,0 +1,2 @@
+s~^bindir=@SQL_BINDIR@~bindir=/usr/bin~g
+s~@working_dir@~/var/lib/bacula~g
diff -Naurp bacula-1.36.2-2/debian/po/fr.po bacula-1.36.2-2sarge1/debian/po/fr.po
--- bacula-1.36.2-2/debian/po/fr.po	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/po/fr.po	2005-05-20 09:07:19.000000000 +0000
@@ -15,8 +15,8 @@ msgid ""
 msgstr ""
 "Project-Id-Version: bacula\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2005-03-22 13:20+0000\n"
-"PO-Revision-Date: 2005-03-29 20:30+0200\n"
+"POT-Creation-Date: 2005-05-11 01:35+0000\n"
+"PO-Revision-Date: 2005-05-14 16:30+0200\n"
 "Last-Translator: Eric Madesclair <eric-m@wanadoo.fr>\n"
 "Language-Team: French <debian-l10n-french@lists.debian.org>\n"
 "MIME-Version: 1.0\n"
@@ -33,7 +33,7 @@ msgstr "localhost"
 #. Description
 #: ../bacula-director-mysql.templates:4
 msgid "Where is the MySQL server?"
-msgstr "Serveur MySQL :"
+msgstr "Nom du serveur MySQL :"
 
 #. Type: string
 #. Description
@@ -54,7 +54,7 @@ msgstr "bacula"
 #. Description
 #: ../bacula-director-mysql.templates:11
 msgid "MySQL username"
-msgstr "Identifiant de connexion MySQL :"
+msgstr "Identifiant MySQL :"
 
 #. Type: string
 #. Description
@@ -62,13 +62,13 @@ msgstr "Identifiant de connexion MySQL :
 msgid "Please, enter the username which Bacula will use to connect to MySQL."
 msgstr ""
 "Veuillez indiquer l'identifiant qui sera utilisé par Bacula pour la "
-"connexion au serveur MySQL."
+"connexion MySQL."
 
 #. Type: password
 #. Description
 #: ../bacula-director-mysql.templates:17
 msgid "MySQL password"
-msgstr "Mot de passe de connexion MySQL :"
+msgstr "Mot de passe MySQL :"
 
 #. Type: password
 #. Description
@@ -76,7 +76,7 @@ msgstr "Mot de passe de connexion MySQL 
 msgid "Please, enter the password which Bacula will use to connect to MySQL."
 msgstr ""
 "Veuillez indiquer le mot de passe qui sera utilisé par Bacula pour la "
-"connexion au serveur MySQL."
+"connexion MySQL."
 
 #. Type: boolean
 #. Description
@@ -101,8 +101,7 @@ msgstr ""
 #: ../bacula-director-mysql.templates:23
 msgid "A MySQL 'root' username & password will be required."
 msgstr ""
-"L'identifiant et le mot de passe d'un administrateur du serveur de bases de "
-"données MySQL sont nécessaires."
+"L'identifiant et le mot de passe d'un administrateur MySQL sont nécessaires."
 
 #. Type: string
 #. Default
@@ -114,22 +113,19 @@ msgstr "root"
 #. Description
 #: ../bacula-director-mysql.templates:32
 msgid "MySQL 'root' username"
-msgstr "Identifiant de l'administrateur de MySQL :"
+msgstr "Identifiant de l'administrateur MySQL :"
 
 #. Type: string
 #. Description
 #: ../bacula-director-mysql.templates:32
 msgid "Please type the username to connect to MySQL as."
-msgstr ""
-"Veuillez indiquer l'identifiant de l'administrateur du serveur de bases de "
-"données MySQL."
+msgstr "Veuillez indiquer l'identifiant de l'administrateur de MySQL."
 
 #. Type: string
 #. Description
 #: ../bacula-director-mysql.templates:32 ../bacula-director-pgsql.templates:47
 msgid "This user needs to have 'create database' privileges."
-msgstr ""
-"Cet identifiant doit avoir les privilèges de création de bases de données."
+msgstr "Cet identifiant doit avoir les droits pour créer une base de données."
 
 #. Type: password
 #. Default
@@ -147,9 +143,7 @@ msgstr "Mot de passe de l'administrateur
 #. Description
 #: ../bacula-director-mysql.templates:40 ../bacula-director-pgsql.templates:55
 msgid "Please type the password for the username entered before."
-msgstr ""
-"Veuillez indiquer le mot de passe de l'administrateur du serveur de bases de "
-"données MySQL."
+msgstr "Veuillez indiquer le mot de passe de l'administrateur de MySQL."
 
 #. Type: boolean
 #. Description
@@ -165,8 +159,8 @@ msgid ""
 "Shall I remove the Catalog from the MySQL server at package purge time? This "
 "will free all the used space."
 msgstr ""
-"Voulez-vous que le catalogue du serveur MySQL soit supprimé lors de la purge "
-"(désinstallation complète) du paquet ? Ceci libérera tout l'espace utilisé."
+"Le catalogue au serveur MySQL peut être supprimé lors de la purge "
+"(désinstallation complète) du paquet. Ceci libérera tout l'espace utilisé."
 
 #. Type: boolean
 #. Description
@@ -179,13 +173,13 @@ msgid ""
 msgstr ""
 "Attention : cette opération est irréversible. Une fois que vous aurez "
 "supprimé le catalogue, vous ne serez plus en mesure de restaurer vos "
-"sauvegardes, à moins d'avoir conservé une copie du catalogue actuel."
+"sauvegardes moins d'avoir une autre copie du catalogue actuel."
 
 #. Type: string
 #. Description
 #: ../bacula-director-pgsql.templates:4
 msgid "Where is the PostgreSQL server?"
-msgstr "Serveur PostgreSQL :"
+msgstr "Nom du serveur PostgreSQL :"
 
 #. Type: string
 #. Description
@@ -201,7 +195,7 @@ msgstr ""
 #. Description
 #: ../bacula-director-pgsql.templates:11
 msgid "PostgreSQL username"
-msgstr "Identifiant de connexion PostgreSQL :"
+msgstr "Identifiant PostgreSQL :"
 
 #. Type: string
 #. Description
@@ -210,13 +204,13 @@ msgid ""
 "Please, enter the username which Bacula will use to connect to PostgreSQL."
 msgstr ""
 "Veuillez indiquer l'identifiant qui sera utilisé par Bacula pour la "
-"connexion au serveur de bases de données PostgreSQL."
+"connexion PostgreSQL."
 
 #. Type: password
 #. Description
 #: ../bacula-director-pgsql.templates:17
 msgid "PostgreSQL password"
-msgstr "Mot de passe de connexion PostgreSQL :"
+msgstr "Mot de passe PostgreSQL :"
 
 #. Type: password
 #. Description
@@ -225,7 +219,7 @@ msgid ""
 "Please, enter the password which Bacula will use to connect to PostgreSQL."
 msgstr ""
 "Veuillez indiquer le mot de passe qui sera utilisé par Bacula pour la "
-"connexion au serveur de bases de données PostgreSQL."
+"connexion PostgreSQL."
 
 #. Type: boolean
 #. Description
@@ -248,8 +242,8 @@ msgstr ""
 #: ../bacula-director-pgsql.templates:32
 msgid "A PgSQL 'admin' username & password will be required."
 msgstr ""
-"L'identifiant et le mot de passe d'un administrateur du serveur de bases de "
-"données PostgreSQL sont nécessaires."
+"L'identifiant et le mot de passe d'un administrateur PostgreSQL sont "
+"nécessaires."
 
 #. Type: boolean
 #. Description
@@ -273,9 +267,7 @@ msgstr "Identifiant de l'administrateur 
 #. Description
 #: ../bacula-director-pgsql.templates:47
 msgid "Please type the username to connect to PostgreSQL as."
-msgstr ""
-"Veuillez indiquer l'identifiant de l'administrateur du serveur de bases de "
-"données PostgreSQL."
+msgstr "Veuillez indiquer l'identifiant de l'administrateur de PostgreSQL."
 
 #. Type: password
 #. Description
@@ -290,9 +282,8 @@ msgid ""
 "Shall I remove the Catalog from the PostgreSQL server at package purge time? "
 "This will free all the used space."
 msgstr ""
-"Voulez-vous que le catalogue du serveur PostgreSQL soit supprimé lors de la "
-"purge (désinstallation complète) du paquet ? Ceci libérera tout l'espace "
-"utilisé."
+"Le catalogue au serveur PostgreSQL peut être supprimé lors de la purge "
+"(désinstallation complète) du paquet. Ceci libérera tout l'espace utilisé."
 
 #. Type: boolean
 #. Description
@@ -312,6 +303,6 @@ msgid ""
 "Shall I remove the Catalog / SQLite database at package purge time? This "
 "will free all the used space."
 msgstr ""
-"Voulez-vous que le catalogue de la base de données SQLite soit supprimé lors "
-"de la purge (désinstallation complète) du paquet ? Ceci libérera tout "
-"l'espace utilisé."
+"Le catalogue de la base de données SQLite peut être supprimé lors de la "
+"purge (désinstallation complète) du paquet. Ceci libérera toutl'espace "
+"utilisé."
diff -Naurp bacula-1.36.2-2/debian/rules bacula-1.36.2-2sarge1/debian/rules
--- bacula-1.36.2-2/debian/rules	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/debian/rules	2005-05-20 09:07:19.000000000 +0000
@@ -245,15 +245,22 @@ install-common: build
 	for pkg in ${FLAVORS}; do \
 		eval flavor="`echo $$pkg | sed -e 's@pgsql@postgresql@'`"; \
 		for f in make update; do \
-			cat src/cats/$${f}_$${flavor}_tables.in | sed -f debian/patches/fix_scripts.sed \
+			cat src/cats/$${f}_$${flavor}_tables.in | sed -f debian/patches/fix_sql.sed \
 			> debian/tmp/scripts/$${f}_$${pkg}_tables; \
 			chmod 755 debian/tmp/scripts/$${f}_$${pkg}_tables; \
 		done; \
 	done
-	cat src/cats/grant_postgresql_privileges.in | sed -f debian/patches/fix_scripts.sed \
+	cat src/cats/grant_postgresql_privileges.in | sed -f debian/patches/fix_sql.sed \
 		> debian/tmp/scripts/grant_pgsql_privileges
 	chmod 755 debian/tmp/scripts/grant_pgsql_privileges
 
+	for file in debian/tmp/etc/bacula/scripts/*; do \
+		mv $${file} $${file}.orig ; \
+		sed -f debian/patches/fix_scripts.sed $${file}.orig > $${file}; \
+		chmod +x $${file}; \
+		rm -f $${file}.orig ; \
+	done
+
 	dh_install -pbacula-director-common
 
 	dh_install -pbacula-fd
@@ -345,7 +352,7 @@ binary-indep: build install patch
 	dh_installinfo -i
 	dh_installchangelogs ChangeLog -i
 	dh_link -i
-	dh_compress -i
+	dh_compress -i -X.pdf
 	dh_fixperms -i
 	dh_installdeb -i
 	dh_gencontrol -i
diff -Naurp bacula-1.36.2-2/src/dird/dird.h bacula-1.36.2-2sarge1/src/dird/dird.h
--- bacula-1.36.2-2/src/dird/dird.h	2004-04-19 14:27:00.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/dird/dird.h	2005-05-20 09:07:19.000000000 +0000
@@ -3,7 +3,7 @@
  *
  *     Kern Sibbald, December MM
  *
- *    Version $Id: dird.h,v 1.7 2004/04/19 14:27:00 kerns Exp $
+ *    Version $Id: dird.h,v 1.7.14.1 2005/04/05 17:23:54 kerns Exp $
  */
 /*
    Copyright (C) 2000-2004 Kern Sibbald and John Walker
@@ -45,3 +45,4 @@ extern int SDConnectTimeout;
 
 /* From job.c */
 void dird_free_jcr(JCR *jcr);
+void dird_free_jcr_pointers(JCR *jcr);
diff -Naurp bacula-1.36.2-2/src/dird/job.c bacula-1.36.2-2sarge1/src/dird/job.c
--- bacula-1.36.2-2/src/dird/job.c	2005-02-27 21:53:28.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/dird/job.c	2005-05-20 09:07:19.000000000 +0000
@@ -676,15 +676,9 @@ void create_unique_job_name(JCR *jcr, co
    }
 }
 
-/*
- * Free the Job Control Record if no one is still using it.
- *  Called from main free_jcr() routine in src/lib/jcr.c so
- *  that we can do our Director specific cleanup of the jcr.
- */
-void dird_free_jcr(JCR *jcr)
+/* Called directly from job rescheduling */
+void dird_free_jcr_pointers(JCR *jcr)
 {
-   Dmsg0(200, "Start dird free_jcr\n");
-
    if (jcr->sd_auth_key) {
       free(jcr->sd_auth_key);
       jcr->sd_auth_key = NULL;
@@ -723,7 +717,21 @@ void dird_free_jcr(JCR *jcr)
    }
    if (jcr->term_wait_inited) {
       pthread_cond_destroy(&jcr->term_wait);
+      jcr->term_wait_inited = false;
    }
+}
+
+/*
+ * Free the Job Control Record if no one is still using it.
+ *  Called from main free_jcr() routine in src/lib/jcr.c so
+ *  that we can do our Director specific cleanup of the jcr.
+ */
+void dird_free_jcr(JCR *jcr)
+{
+   Dmsg0(200, "Start dird free_jcr\n");
+
+   dird_free_jcr_pointers(jcr);
+
    /* Delete lists setup to hold storage pointers */
    for (int i=0; i<MAX_STORE; i++) {
       if (jcr->storage[i]) {
@@ -822,13 +830,13 @@ void copy_storage(JCR *new_jcr, JCR *old
    for (int i=0; i < MAX_STORE; i++) {
       if (old_jcr->storage[i]) {
 	 STORE *st;
-	 if (old_jcr->storage[i]) {
-	    delete old_jcr->storage[i];
-	 }
 	 new_jcr->storage[i] = New(alist(10, not_owned_by_alist));
 	 foreach_alist(st, old_jcr->storage[i]) {
 	    new_jcr->storage[i]->append(st);
 	 }
+         if (old_jcr->storage[i]) {
+            delete old_jcr->storage[i];
+         }
       }
       if (old_jcr->store) {
 	 new_jcr->store = old_jcr->store;
diff -Naurp bacula-1.36.2-2/src/dird/jobq.c bacula-1.36.2-2sarge1/src/dird/jobq.c
--- bacula-1.36.2-2/src/dird/jobq.c	2005-02-15 11:51:03.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/dird/jobq.c	2005-05-20 09:07:19.000000000 +0000
@@ -10,7 +10,7 @@
  *
  *  Kern Sibbald, July MMIII
  *
- *   Version $Id: jobq.c,v 1.25.4.2 2005/02/15 11:51:03 kerns Exp $
+ *   Version $Id: jobq.c,v 1.25.4.2.2.1 2005/04/05 17:23:55 kerns Exp $
  *
  *  This code was adapted from the Bacula workq, which was
  *    adapted from "Programming with POSIX Threads", by
@@ -481,7 +481,7 @@ void *jobq_server(void *arg)
 	    bstrftime(dt, sizeof(dt), time(NULL));
             Jmsg(jcr, M_INFO, 0, _("Rescheduled Job %s at %s to re-run in %d seconds.\n"),
 	       jcr->Job, dt, (int)jcr->job->RescheduleInterval);
-	    dird_free_jcr(jcr); 	 /* partial cleanup old stuff */
+	    dird_free_jcr_pointers(jcr);     /* partial cleanup old stuff */
 	    jcr->JobStatus = JS_WaitStartTime;
 	    jcr->SDJobStatus = 0;
 	    if (jcr->JobBytes == 0) {
@@ -584,7 +584,7 @@ void *jobq_server(void *arg)
 		   if (njcr->JobId == 0 || njcr == jcr) {
 		      continue;
 		   }
-		   if (njcr->pool != jcr->pool) {
+		   if (njcr->store == jcr->store && njcr->pool != jcr->pool) {
 		      skip_this_jcr = true;
 		      break;
 		   }
diff -Naurp bacula-1.36.2-2/src/dird/msgchan.c bacula-1.36.2-2sarge1/src/dird/msgchan.c
--- bacula-1.36.2-2/src/dird/msgchan.c	2005-02-14 10:02:21.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/dird/msgchan.c	2005-05-20 09:07:19.000000000 +0000
@@ -13,7 +13,7 @@
  *    Create a thread to interact with the Storage daemon
  *	who returns a job status and requests Catalog services, etc.
  *
- *   Version $Id: msgchan.c,v 1.32.4.1 2005/02/14 10:02:21 kerns Exp $
+ *   Version $Id: msgchan.c,v 1.32.4.1.2.1 2005/04/05 17:23:55 kerns Exp $
  */
 /*
    Copyright (C) 2000-2004 Kern Sibbald
@@ -66,6 +66,10 @@ bool connect_to_storage_daemon(JCR *jcr,
    BSOCK *sd;
    STORE *store;
 
+   if (!jcr->storage[0]) {
+      Jmsg(jcr, M_FATAL, 0, _("Attempt to contact the Storage daemon with no Storage resource.\n"));
+      return false;
+   }
    store = (STORE *)jcr->storage[0]->first();
 
    /*
diff -Naurp bacula-1.36.2-2/src/filed/job.c bacula-1.36.2-2sarge1/src/filed/job.c
--- bacula-1.36.2-2/src/filed/job.c	2005-02-25 09:47:06.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/filed/job.c	2005-05-20 09:07:19.000000000 +0000
@@ -3,7 +3,7 @@
  *
  *    Kern Sibbald, October MM
  *
- *   Version $Id: job.c,v 1.91.4.2 2005/02/25 09:47:06 kerns Exp $
+ *   Version $Id: job.c,v 1.91.4.2.2.1 2005/03/04 09:14:16 kerns Exp $
  *
  */
 /*
@@ -1139,7 +1139,7 @@ static int level_cmd(JCR *jcr)
       buf = get_memory(dir->msglen+1);
       utime_t since_time, adj;
       btime_t his_time, bt_start, rt=0, bt_adj=0;
-      if (jcr->JobLevel == 0) {
+      if (jcr->JobLevel == L_NONE) {
 	 jcr->JobLevel = L_SINCE;     /* if no other job level set, do it now */
       }
       if (sscanf(dir->msg, "level = since_utime %s mtime_only=%d",
diff -Naurp bacula-1.36.2-2/src/findlib/create_file.c bacula-1.36.2-2sarge1/src/findlib/create_file.c
--- bacula-1.36.2-2/src/findlib/create_file.c	2004-07-27 21:00:33.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/findlib/create_file.c	2005-05-20 09:07:19.000000000 +0000
@@ -3,7 +3,7 @@
  *
  *    Kern Sibbald, November MM
  *
- *   Version $Id: create_file.c,v 1.34 2004/07/27 21:00:33 kerns Exp $
+ *   Version $Id: create_file.c,v 1.34.10.2 2005/04/12 21:31:20 kerns Exp $
  *
  */
 /*
@@ -271,6 +271,12 @@ int create_file(JCR *jcr, ATTR *attr, BF
 	 if ((bopen(bfd, attr->ofname, O_WRONLY|O_BINARY, 0)) < 0) {
 	    berrno be;
 	    be.set_errno(bfd->berrno);
+#ifdef HAVE_WIN32
+	    /* Check for trying to create a drive, if so, skip */
+            if (attr->ofname[1] == ':' && attr->ofname[2] == '/' && attr->ofname[3] == 0) {
+	       return CF_SKIP;
+	    }
+#endif
             Jmsg2(jcr, M_ERROR, 0, _("Could not open %s: ERR=%s\n"), 
 		  attr->ofname, be.strerror());
 	    return CF_ERROR;
diff -Naurp bacula-1.36.2-2/src/jcr.h bacula-1.36.2-2sarge1/src/jcr.h
--- bacula-1.36.2-2/src/jcr.h	2005-02-27 21:53:28.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/jcr.h	2005-05-20 09:07:19.000000000 +0000
@@ -6,7 +6,7 @@
  *
  * Kern Sibbald, Nov MM
  *
- *   Version $Id: jcr.h,v 1.76.4.1 2005/02/27 21:53:28 kerns Exp $
+ *   Version $Id: jcr.h,v 1.76.4.1.2.1 2005/04/05 17:23:50 kerns Exp $
  */
 
 /*
@@ -243,6 +243,7 @@ struct JCR {
 
    /* Parmaters for Open Read Session */
    BSR *bsr;                          /* Bootstrap record -- has everything */
+   bool mount_next_volume;            /* set to cause next volume mount */
    uint32_t read_VolSessionId;
    uint32_t read_VolSessionTime;
    uint32_t read_StartFile;
diff -Naurp bacula-1.36.2-2/src/stored/read_record.c bacula-1.36.2-2sarge1/src/stored/read_record.c
--- bacula-1.36.2-2/src/stored/read_record.c	2005-02-15 11:51:04.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/stored/read_record.c	2005-05-20 09:07:19.000000000 +0000
@@ -57,6 +57,7 @@ bool read_records(DCR *dcr,
 
    recs = New(dlist(rec, &rec->link));
    position_to_first_file(jcr, dev);
+   jcr->mount_next_volume = false;
 
    for ( ; ok && !done; ) {
       if (job_canceled(jcr)) {
@@ -81,8 +82,13 @@ bool read_records(DCR *dcr,
 	       trec->File = dev->file;
 	       ok = record_cb(dcr, trec);
 	       free_record(trec);
+	       if (jcr->mount_next_volume) {
+		  jcr->mount_next_volume = false;
+		  dev->state &= ~ST_EOT;
+	       }
 	       break;
 	    }
+	    jcr->mount_next_volume = false;
 	    /*
 	     * We just have a new tape up, now read the label (first record)
 	     *	and pass it off to the callback routine, then continue
@@ -113,7 +119,7 @@ bool read_records(DCR *dcr,
 	    display_tape_error_status(jcr, dev);
 	    if (forge_on || jcr->ignore_label_errors) {
 	       fsr_dev(dev, 1);       /* try skipping bad record */
-               Dmsg0(000, "Did fsr\n");
+               Pmsg0(000, "Did fsr\n");
 	       continue;	      /* try to continue */
 	    }
 	    ok = false;
@@ -259,7 +265,11 @@ static int try_repositioning(JCR *jcr, D
       Dmsg2(300, "Current postion (file:block) %d:%d\n",
 	 dev->file, dev->block_num);
       jcr->bsr->mount_next_volume = false;
-//    dev->state |= ST_EOT;
+      if (!dev->at_eot()) {
+	 /* Set EOT flag to force mount of next Volume */
+	 jcr->mount_next_volume = true;
+	 dev->state |= ST_EOT;
+      }
       rec->Block = 0;
       return 1;
    }
diff -Naurp bacula-1.36.2-2/src/stored/spool.c bacula-1.36.2-2sarge1/src/stored/spool.c
--- bacula-1.36.2-2/src/stored/spool.c	2005-02-15 11:51:04.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/stored/spool.c	2005-05-20 09:07:19.000000000 +0000
@@ -3,10 +3,10 @@
  *
  *	Kern Sibbald, March 2004
  *
- *  Version $Id: spool.c,v 1.22.4.2 2005/02/15 11:51:04 kerns Exp $
+ *  Version $Id: spool.c,v 1.22.4.2.2.3 2005/04/23 11:30:19 kerns Exp $
  */
 /*
-   Copyright (C) 2004-2004 Kern Sibbald and John Walker
+   Copyright (C) 2004-2005 Kern Sibbald
 
    This program is free software; you can redistribute it and/or
    modify it under the terms of the GNU General Public License as
@@ -527,22 +527,27 @@ static void update_attr_spool_size(ssize
 
 bool commit_attribute_spool(JCR *jcr)
 {
-   ssize_t size;
+   off_t size;
    char ec1[30];
 
    if (are_attributes_spooled(jcr)) {
-      if (fseek(jcr->dir_bsock->spool_fd, 0, SEEK_END) != 0) {
+      if (fseeko(jcr->dir_bsock->spool_fd, 0, SEEK_END) != 0) {
 	 berrno be;
          Jmsg(jcr, M_FATAL, 0, _("Fseek on attributes file failed: ERR=%s\n"),
 	      be.strerror());
+         goto bail_out;
+      }
+      size = ftello(jcr->dir_bsock->spool_fd);
+      if (size < 0) {
+         berrno be;
+         Jmsg(jcr, M_FATAL, 0, _("Ftell on attributes file failed: ERR=%s\n"),
+              be.strerror());
+         goto bail_out;
       }
-      size = ftell(jcr->dir_bsock->spool_fd);
       P(mutex);
-      if (size > 0) {
 	if (spool_stats.attr_size + size > spool_stats.max_attr_size) {
 	   spool_stats.max_attr_size = spool_stats.attr_size + size;
 	}
-      }
       spool_stats.attr_size += size;
       V(mutex);
       Jmsg(jcr, M_INFO, 0, _("Sending spooled attrs to the Director. Despooling %s bytes ...\n"),
@@ -551,6 +556,10 @@ bool commit_attribute_spool(JCR *jcr)
       return close_attr_spool_file(jcr, jcr->dir_bsock);
    }
    return true;
+
+bail_out:
+   close_attr_spool_file(jcr, jcr->dir_bsock);
+   return false;
 }
 
 static void make_unique_spool_filename(JCR *jcr, POOLMEM **name, int fd)
diff -Naurp bacula-1.36.2-2/src/tray-monitor/tray-monitor.c bacula-1.36.2-2sarge1/src/tray-monitor/tray-monitor.c
--- bacula-1.36.2-2/src/tray-monitor/tray-monitor.c	2005-02-25 09:47:07.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/tray-monitor/tray-monitor.c	2005-05-20 09:07:19.000000000 +0000
@@ -47,7 +47,6 @@ void getstatus(monitoritem* item, int cu
 /* Static variables */
 static char *configfile = NULL;
 static MONITOR *monitor;
-static POOLMEM *args;
 static JCR jcr;
 static int nitems = 0;
 static int fullitem = 0; //Item to be display in detailled status window
@@ -133,6 +132,8 @@ static GtkWidget *new_image_button(const
     return button;
 }
 
+int sm_line = 0;
+
 /*********************************************************************
  *
  *	   Main Bacula Tray Monitor -- User Interface Program
@@ -151,7 +152,6 @@ int main(int argc, char *argv[])
    textdomain("bacula");
    init_msg(NULL, NULL);
    working_directory = "/tmp";
-   args = get_pool_memory(PM_FNAME);
 
    struct sigaction sigignore;
    sigignore.sa_flags = 0;
@@ -252,7 +252,7 @@ int main(int argc, char *argv[])
    //Copy the content of xpm_generic in xpm_generic_var to be able to modify it
    g_assert((xpm_generic_var = (char**)g_malloc(sizeof(xpm_generic))));
    for (i = 0; i < (int)(sizeof(xpm_generic)/sizeof(const char*)); i++) {
-      g_assert((xpm_generic_var[i] = (char*)g_malloc(strlen(xpm_generic[i])*sizeof(char))));
+      g_assert((xpm_generic_var[i] = (char*)g_malloc((strlen(xpm_generic[i])+1)*sizeof(char))));
       strcpy(xpm_generic_var[i], xpm_generic[i]);
    }
 
@@ -410,6 +410,10 @@ int main(int argc, char *argv[])
    gtk_widget_show_all(vbox);
 
    gtk_main();
+   
+   g_source_remove(timerTag);
+   
+   sm_line = 0;
 
    for (i = 0; i < nitems; i++) {
       if (items[i].D_sock) {
@@ -419,7 +423,6 @@ int main(int argc, char *argv[])
       }
    }
 
-   free_pool_memory(args);
    (void)WSACleanup();		     /* Cleanup Windows sockets */
 
    //Free xpm_generic_var
@@ -427,6 +430,10 @@ int main(int argc, char *argv[])
       g_free(xpm_generic_var[i]);
    }
    g_free(xpm_generic_var);
+   
+   gtk_object_destroy(GTK_OBJECT(window));
+   gtk_object_destroy(GTK_OBJECT(mTrayMenu));
+   term_msg();
 
    return 0;
 }
@@ -531,7 +538,8 @@ static gboolean blink(gpointer data) {
 }
 
 static gboolean fd_read(gpointer data) {
-   GtkTextBuffer *newbuffer = gtk_text_buffer_new(NULL);
+   sm_line++;
+   GtkTextBuffer *newbuffer;
    GtkTextIter start, stop, nstart, nstop;
 
    GSList *list, *it;
@@ -544,6 +552,8 @@ static gboolean fd_read(gpointer data) {
    }
 
    if (lastupdated == fullitem) {
+      newbuffer = gtk_text_buffer_new(NULL);
+      
       if (items[lastupdated].type == R_DIRECTOR)
 	 docmd(&items[lastupdated], "status Director\n", &list);
       else
@@ -556,6 +566,8 @@ static gboolean fd_read(gpointer data) {
 	 if (it->data) g_string_free((GString*)it->data, TRUE);
       } while ((it = it->next) != NULL);
 
+      g_slist_free(list);
+            
       /* Keep the selection if necessary */
       if (gtk_text_buffer_get_selection_bounds(buffer, &start, &stop)) {
 	 gtk_text_buffer_get_iter_at_offset(newbuffer, &nstart, gtk_text_iter_get_offset(&start));
@@ -961,6 +973,7 @@ void updateStatusIcon(monitoritem* item)
    else {
       gtk_image_set_from_pixbuf(GTK_IMAGE(item->image), pixbuf);
    }
+   g_object_unref(G_OBJECT(pixbuf));
 }
 
 /* Note: result should not be stored, as it is a reference to xpm_generic_var */
diff -Naurp bacula-1.36.2-2/src/wx-console/CHANGELOG bacula-1.36.2-2sarge1/src/wx-console/CHANGELOG
--- bacula-1.36.2-2/src/wx-console/CHANGELOG	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/wx-console/CHANGELOG	2005-05-20 09:07:19.000000000 +0000
@@ -1,3 +1,9 @@
+24-03-2005 :
+ - wxbMainFrame : Fix a bug with GTK+-1.2 which caused wx-console to crash
+   when starting.
+ - wxbRestorePanel : Fix a major bug which caused wx-console to enter in an
+   infinite loop which allocate a lot of memory and could make the system crash.
+
 10-03-2005 :
  - wxbMainFrame : Fix bug #0000221 (Debian 292517)
 
diff -Naurp bacula-1.36.2-2/src/wx-console/wxbmainframe.cpp bacula-1.36.2-2sarge1/src/wx-console/wxbmainframe.cpp
--- bacula-1.36.2-2/src/wx-console/wxbmainframe.cpp	2005-05-20 08:57:16.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/wx-console/wxbmainframe.cpp	2005-05-20 09:07:19.000000000 +0000
@@ -4,7 +4,7 @@
  *
  *    Nicolas Boichat, July 2004
  *
- *    Version $Id: wxbmainframe.cpp,v 1.30 2004/11/15 16:49:53 nboichat Exp $
+ *    Version $Id: wxbmainframe.cpp,v 1.30.6.2 2005/03/24 14:52:55 nboichat Exp $
  */
 /*
    Copyright (C) 2004 Kern Sibbald and John Walker
@@ -207,6 +207,8 @@ wxbMainFrame::~wxbMainFrame()
 wxbMainFrame::wxbMainFrame(const wxString& title, const wxPoint& pos, const wxSize& size, long style)
       : wxFrame(NULL, -1, title, pos, size, style)
 {
+   lockedbyconsole = false;
+   
    ct = NULL;
    
    promptparser = NULL;
@@ -313,8 +315,6 @@ wxbMainFrame::wxbMainFrame(const wxStrin
    this->SetSize(size);
    EnableConsole(false);
    
-   lockedbyconsole = false;
-   
    consoleBuffer = "";
    
    configfile = "";
diff -Naurp bacula-1.36.2-2/src/wx-console/wxbrestorepanel.cpp bacula-1.36.2-2sarge1/src/wx-console/wxbrestorepanel.cpp
--- bacula-1.36.2-2/src/wx-console/wxbrestorepanel.cpp	2004-08-06 15:14:36.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/wx-console/wxbrestorepanel.cpp	2005-05-20 09:07:19.000000000 +0000
@@ -4,7 +4,7 @@
  *
  *    Nicolas Boichat, April-July 2004
  *
- *    Version $Id: wxbrestorepanel.cpp,v 1.40 2004/08/06 15:14:36 nboichat Exp $
+ *    Version $Id: wxbrestorepanel.cpp,v 1.40.8.1 2005/03/24 14:52:55 nboichat Exp $
  */
 /*
    Copyright (C) 2004 Kern Sibbald and John Walker
@@ -408,7 +408,7 @@ wxbRestorePanel::wxbRestorePanel(wxWindo
 
    SetCursor(*wxSTANDARD_CURSOR);
 
-   markWhenListingDone = false;
+   markWhenCommandDone = false;
    
    cancelled = 0;
 }
@@ -1985,7 +1985,6 @@ void wxbRestorePanel::OnCancel(wxCommand
 
 void wxbRestorePanel::OnStart(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    SetWorking(true);
@@ -1995,14 +1994,12 @@ void wxbRestorePanel::OnStart(wxCommandE
 
 void wxbRestorePanel::OnTreeChanging(wxTreeEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       event.Veto();
    }
 }
 
 void wxbRestorePanel::OnTreeExpanding(wxTreeEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       event.Veto();
       return;
    }
@@ -2016,7 +2013,6 @@ void wxbRestorePanel::OnTreeExpanding(wx
 
 void wxbRestorePanel::OnTreeChanged(wxTreeEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    if (currentTreeItem == event.GetItem()) {
@@ -2025,11 +2021,11 @@ void wxbRestorePanel::OnTreeChanged(wxTr
    treeadd->Enable(false);
    treeremove->Enable(false);
    treerefresh->Enable(false);
-   markWhenListingDone = false;
+   markWhenCommandDone = false;
    SetWorking(true);
    currentTreeItem = event.GetItem();
    CmdList(event.GetItem());
-   if (markWhenListingDone) {
+   if (markWhenCommandDone) {
       CmdMark(event.GetItem(), NULL, 0);
       tree->Refresh();
    }
@@ -2043,17 +2039,19 @@ void wxbRestorePanel::OnTreeChanged(wxTr
 }
 
 void wxbRestorePanel::OnTreeMarked(wxbTreeMarkedEvent& event) {
-   csprint("Tree marked", CS_DEBUG);
    if (IsWorking()) {
       if (tree->GetSelection() == event.GetItem()) {
-         markWhenListingDone = !markWhenListingDone;
+         markWhenCommandDone = !markWhenCommandDone;
       }
-      AddPendingEvent(event);
       return;
    }
    SetWorking(true);
+   markWhenCommandDone = false;
    CmdMark(event.GetItem(), NULL, 0);
-   //event.Skip();
+   if (markWhenCommandDone) {
+      CmdMark(event.GetItem(), NULL, 0);
+      tree->Refresh();
+   }
    tree->Refresh();
    SetWorking(false);
    if (event.GetItem().IsOk()) {
@@ -2065,7 +2063,6 @@ void wxbRestorePanel::OnTreeMarked(wxbTr
 
 void wxbRestorePanel::OnTreeAdd(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
@@ -2081,7 +2078,6 @@ void wxbRestorePanel::OnTreeAdd(wxComman
 
 void wxbRestorePanel::OnTreeRemove(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
@@ -2097,7 +2093,6 @@ void wxbRestorePanel::OnTreeRemove(wxCom
 
 void wxbRestorePanel::OnTreeRefresh(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
@@ -2108,8 +2103,6 @@ void wxbRestorePanel::OnTreeRefresh(wxCo
 
 void wxbRestorePanel::OnListMarked(wxbListMarkedEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
-      //event.Skip();
       return;
    }
    
@@ -2129,7 +2122,7 @@ void wxbRestorePanel::OnListMarked(wxbLi
       num++;
       item = list->GetNextItem(item, wxLIST_NEXT_ALL, wxLIST_STATE_SELECTED);
    }
-     
+   
    CmdMark(wxTreeItemId(), items, num);
    
    delete[] items;
@@ -2145,8 +2138,6 @@ void wxbRestorePanel::OnListMarked(wxbLi
 
 void wxbRestorePanel::OnListActivated(wxListEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
-      //event.Skip();
       return;
    }
    SetWorking(true);
@@ -2183,7 +2174,6 @@ void wxbRestorePanel::OnListActivated(wx
 
 void wxbRestorePanel::OnListChanged(wxListEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
  
@@ -2220,7 +2210,6 @@ void wxbRestorePanel::OnListChanged(wxLi
 
 void wxbRestorePanel::OnListAdd(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
@@ -2250,7 +2239,6 @@ void wxbRestorePanel::OnListAdd(wxComman
 
 void wxbRestorePanel::OnListRemove(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
@@ -2280,7 +2268,6 @@ void wxbRestorePanel::OnListRemove(wxCom
 
 void wxbRestorePanel::OnListRefresh(wxCommandEvent& event) {
    if (IsWorking()) {
-      AddPendingEvent(event);
       return;
    }
    
diff -Naurp bacula-1.36.2-2/src/wx-console/wxbrestorepanel.h bacula-1.36.2-2sarge1/src/wx-console/wxbrestorepanel.h
--- bacula-1.36.2-2/src/wx-console/wxbrestorepanel.h	2004-07-18 09:33:26.000000000 +0000
+++ bacula-1.36.2-2sarge1/src/wx-console/wxbrestorepanel.h	2005-05-20 09:07:19.000000000 +0000
@@ -4,7 +4,7 @@
  *
  *    Nicolas Boichat, April-May 2004
  *
- *    Version $Id: wxbrestorepanel.h,v 1.19 2004/07/18 09:33:26 kerns Exp $
+ *    Version $Id: wxbrestorepanel.h,v 1.19.10.1 2005/03/24 14:52:56 nboichat Exp $
  */
 /*
    Copyright (C) 2004 Kern Sibbald and John Walker
@@ -151,7 +151,7 @@ class wxbRestorePanel : public wxbPanel
       bool working; // A command is running, discard GUI events
       void SetWorking(bool working);
       bool IsWorking();
-      bool markWhenListingDone;
+      bool markWhenCommandDone; //If an item should be (un)marked after the current listing/marking is done
       wxTreeItemId currentTreeItem; // Currently selected tree item
 
       /* Enable or disable config controls status */

Attachment: signature.asc
Description: OpenPGP digital signature


Reply to: