Ubuntu

Merge lp:~brunoqc/ubuntu/natty/lfm/lfm-fix-786491 into lp:ubuntu/natty/lfm

Proposed by Bruno Bigras on 2011-10-03
Status: Merged
Merge reported by: Martin Pitt
Merged at revision: not available
Proposed branch: lp:~brunoqc/ubuntu/natty/lfm/lfm-fix-786491
Merge into: lp:ubuntu/natty/lfm
Diff against target: 60 lines (+41/-0) 3 files modified
To merge this branch: bzr merge lp:~brunoqc/ubuntu/natty/lfm/lfm-fix-786491
Reviewer Review Type Date Requested Status
Daniel Holbach Approve on 2011-10-06
Ubuntu branches 2011-10-03 Pending
Review via email: mp+77859@code.launchpad.net

Description of the Change

Fix 786491 (this time with the actual patch)

To post a comment you must log in.
Daniel Holbach (dholbach) wrote :

Good work, thanks! I took the liberty of running 'update-maintainer' (https://wiki.ubuntu.com/DebianMaintainerField) and uploaded it, so it should be sitting in the SRU review queue now.

review: Approve

Preview Diff

1=== modified file 'debian/changelog'
2--- debian/changelog 2010-05-24 16:55:24 +0000
3+++ debian/changelog 2011-10-03 05:44:24 +0000
4@@ -1,3 +1,9 @@
5+lfm (2.2-1ubuntu0.11.04.1) natty-proposed; urgency=low
6+
7+ * Fix a crash at startup, because of UnicodeDecodeError (LP: #786491)
8+
9+ -- Bruno Bigras <bigras.bruno@gmail.com> Sat, 17 Sep 2011 22:19:56 -0400
10+
11 lfm (2.2-1) unstable; urgency=low
12
13 * New Upstream release.
14
15=== added file 'debian/patches/fix-lp786491.patch'
16--- debian/patches/fix-lp786491.patch 1970-01-01 00:00:00 +0000
17+++ debian/patches/fix-lp786491.patch 2011-10-03 05:44:24 +0000
18@@ -0,0 +1,34 @@
19+Description: Fix an UnicodeDecodeError by using decode() instead of str()
20+Origin: upstream, https://bitbucket.org/inigoserna/lfm/changeset/8d2021770794
21+Forwarded: not-needed
22+Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/lfm/+bug/786491
23+Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=617229
24+Index: lfm-2.2/lfm/files.py
25+===================================================================
26+--- lfm-2.2.orig/lfm/files.py 2011-09-17 22:07:32.049362240 -0400
27++++ lfm-2.2/lfm/files.py 2011-09-17 22:08:21.719435092 -0400
28+@@ -152,11 +152,11 @@
29+ try:
30+ owner = pwd.getpwuid(st[stat.ST_UID])[0]
31+ except:
32+- owner = str(st[stat.ST_UID])
33++ owner = decode(st[stat.ST_UID])
34+ try:
35+ group = grp.getgrgid(st[stat.ST_GID])[0]
36+ except:
37+- group = str(st[stat.ST_GID])
38++ group = decode(st[stat.ST_GID])
39+ return (typ, stat.S_IMODE(st[stat.ST_MODE]), owner, group,
40+ size, st[stat.ST_MTIME])
41+
42+@@ -228,8 +228,8 @@
43+ else:
44+ mtime = time.strftime('%a %d %b %Y', time.localtime(filevalues[FT_MTIME]))
45+ mtime2 = time.strftime('%d %b %Y', time.localtime(filevalues[FT_MTIME]))
46+- res['mtime'] = mtime
47+- res['mtime2'] = mtime2
48++ res['mtime'] = decode(mtime)
49++ res['mtime2'] = decode(mtime2)
50+ return res
51+
52+
53
54=== modified file 'debian/patches/series'
55--- debian/patches/series 2010-05-24 16:55:24 +0000
56+++ debian/patches/series 2011-10-03 05:44:24 +0000
57@@ -1,2 +1,3 @@
58 ignore_COPYING.patch
59 debian-changes-2.2-1
60+fix-lp786491.patch

Subscribers

People subscribed via source and target branches

to all changes: