control: tags 816200 +patch
control: affects -1 +bitlbee-dev

Dear maintainer,

I encountered this bug today while attempting to build a package that
build-depends on bitlbee-dev with sbuild, when bitlbee was installed
outside the chroot.  That means that the bitlbee user is visible from
within the chroot, but there is no /var/lib/bitlbee in the chroot,
triggering the bug.

I enclose a patch.

Regards.

-- 
Sean Whitton
diff -u bitlbee-3.5.1/debian/bitlbee-common.postinst bitlbee-3.5.1/debian/bitlbee-common.postinst
--- bitlbee-3.5.1/debian/bitlbee-common.postinst
+++ bitlbee-3.5.1/debian/bitlbee-common.postinst
@@ -34,7 +34,9 @@
 	adduser --system --group --disabled-login --disabled-password --home /var/lib/bitlbee/ bitlbee
 fi
 
-chmod 700 /var/lib/bitlbee/
+if [ -d /var/lib/bitlbee ]; then
+    chmod 700 /var/lib/bitlbee/
+fi
 
 ## Can't do this in packaging phase: Don't know the UID yet. Access to
 ## the file should be limited, now that it stores passwords. Added
diff -u bitlbee-3.5.1/debian/changelog bitlbee-3.5.1/debian/changelog
--- bitlbee-3.5.1/debian/changelog
+++ bitlbee-3.5.1/debian/changelog
@@ -1,3 +1,11 @@
+bitlbee (3.5.1-1.1) unstable; urgency=medium
+
+  * Non-maintainer upload.
+  * Add existence check to chmod call in bitlbee-common.postinst
+    (Closes: #816200).
+
+ -- Sean Whitton <spwhit...@spwhitton.name>  Sat, 18 Mar 2017 13:49:47 -0700
+
 bitlbee (3.5.1-1) unstable; urgency=medium
 
   * Crash bug fix. (Closes: #853282)

Attachment: signature.asc
Description: PGP signature

Reply via email to