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

Bug#613151: pu: package sobby/0.4.7-2+lenny1



Package: release.debian.org
Severity: normal
User: release.debian.org@packages.debian.org
Usertags: pu

Hi,

#613085 got reported yesterday, which is about data-loss on a simple
installation of Sobby due to the fact that it cannot write its session
serialization file as it's owned by root at that time.

I uploaded a fix to unstable (0.4.7-3), would the diff be acceptable?

Kind regards
Philipp Kern
Base version: sobby_0.4.7-2 from testing
Target version: sobby_0.4.7-3 from unstable

No hints in place.

 debian/prerm                  |   14 ++++++++++++++
 sobby-0.4.7/debian/changelog  |   10 ++++++++++
 sobby-0.4.7/debian/sobby.init |    1 +
 3 files changed, 25 insertions(+)

diff -u sobby-0.4.7/debian/sobby.init sobby-0.4.7/debian/sobby.init
--- sobby-0.4.7/debian/sobby.init
+++ sobby-0.4.7/debian/sobby.init
@@ -39,6 +39,7 @@
  user_table
  chat
 EOF
+	chown sobby: "$SOBBY_SESSION_FILE"
 }
 
 do_start() {
diff -u sobby-0.4.7/debian/changelog sobby-0.4.7/debian/changelog
--- sobby-0.4.7/debian/changelog
+++ sobby-0.4.7/debian/changelog
@@ -1,3 +1,13 @@
+sobby (0.4.7-3) unstable; urgency=low
+
+  * The init script creates a new session file if it does not exist yet.
+    Add a chown call to make it writeable by sobby, which is not run
+    as root.  Make sure to chown the file before sobby's stopped, in
+    prerm, so that the write on termination has a chance to succeed.
+    (Closes: #613085)
+
+ -- Philipp Kern <pkern@debian.org>  Sat, 12 Feb 2011 21:09:04 +0100
+
 sobby (0.4.7-2) unstable; urgency=low
 
   * Add an init script by adapting an initial proposal by Dustin Kirkland.
only in patch2:
unchanged:
--- sobby-0.4.7.orig/debian/prerm
+++ sobby-0.4.7/debian/prerm
@@ -0,0 +1,14 @@
+#!/bin/sh
+# vim:set et ts=2 sw=2:
+
+set -e
+
+# Make sure the autosave file is actually writeable before stopping the
+# server.
+if [ -d /var/lib/sobby ]; then
+  chown -R sobby:sobby /var/lib/sobby
+  chmod 0750 /var/lib/sobby
+fi
+
+#DEBHELPER#
+
Hints needed:
unblock sobby/0.4.7-3

Reply to: