[Python-apps-commits] r11319 - in packages/pdfshuffler/trunk/debian (3 files)

sharky at users.alioth.debian.org sharky at users.alioth.debian.org
Sat Sep 27 12:40:44 UTC 2014


    Date: Saturday, September 27, 2014 @ 12:40:43
  Author: sharky
Revision: 11319

fix "Attempt to unlock mutex that was not locked" error

Added:
  packages/pdfshuffler/trunk/debian/patches/fix-threading
Modified:
  packages/pdfshuffler/trunk/debian/changelog
  packages/pdfshuffler/trunk/debian/patches/series

Modified: packages/pdfshuffler/trunk/debian/changelog
===================================================================
--- packages/pdfshuffler/trunk/debian/changelog	2014-09-27 12:37:55 UTC (rev 11318)
+++ packages/pdfshuffler/trunk/debian/changelog	2014-09-27 12:40:43 UTC (rev 11319)
@@ -1,6 +1,7 @@
 pdfshuffler (0.6.0-6) UNRELEASED; urgency=medium
 
   * Fall back to PyPDF2 if pyPdf is not found (Closes: #762083).
+  * Fix "Attempt to unlock mutex that was not locked" error.
   * Add myself to uploaders.
 
  -- Jeremy Lainé <jeremy.laine at m4x.org>  Sat, 27 Sep 2014 09:47:01 +0200

Added: packages/pdfshuffler/trunk/debian/patches/fix-threading
===================================================================
--- packages/pdfshuffler/trunk/debian/patches/fix-threading	                        (rev 0)
+++ packages/pdfshuffler/trunk/debian/patches/fix-threading	2014-09-27 12:40:43 UTC (rev 11319)
@@ -0,0 +1,38 @@
+From: Jeremy Lainé <jeremy.laine at m4x.org>
+Subject: fix threading code
+
+Without this patch, pdfshuffler immediately fails with the following error:
+
+    Attempt to unlock mutex that was not locked
+    Aborted
+
+A similar issue was reported against reportbug:
+
+    https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=758619
+
+--- a/pdfshuffler/pdfshuffler.py	2012-04-28 16:15:17.000000000 +0200
++++ b/pdfshuffler/pdfshuffler.py	2014-09-27 14:33:07.413122319 +0200
+@@ -326,11 +326,9 @@
+   
+     def update_thumbnail(self, object, num, thumbnail, resample):
+         row = self.model[num]
+-        gtk.gdk.threads_enter()
+         row[13] = resample
+         row[4] = self.zoom_scale
+         row[1] = thumbnail
+-        gtk.gdk.threads_leave()
+ 
+     def on_window_size_request(self, window, event):
+         """Main Window resize - workaround for autosetting of
+@@ -1080,9 +1078,10 @@
+ def main():
+     """This function starts PdfShuffler"""
+     gtk.gdk.threads_init()
+-    gobject.threads_init()
++    gtk.gdk.threads_enter()
+     PdfShuffler()
+     gtk.main()
++    gtk.gdk.threads_leave()
+ 
+ if __name__ == '__main__':
+     main()

Modified: packages/pdfshuffler/trunk/debian/patches/series
===================================================================
--- packages/pdfshuffler/trunk/debian/patches/series	2014-09-27 12:37:55 UTC (rev 11318)
+++ packages/pdfshuffler/trunk/debian/patches/series	2014-09-27 12:40:43 UTC (rev 11319)
@@ -1,2 +1,3 @@
 fix-manpage-typo
+fix-threading
 use-pypdf2




More information about the Python-apps-commits mailing list