Merge lp:~niedbalski/ubuntu/wily/multipath-tools/fix-lp-1469143 into lp:ubuntu/wily/multipath-tools

Proposed by Jorge Niedbalski
Status: Rejected
Rejected by: Mathieu Trudel-Lapierre
Proposed branch: lp:~niedbalski/ubuntu/wily/multipath-tools/fix-lp-1469143
Merge into: lp:ubuntu/wily/multipath-tools
Diff against target: 59 lines (+39/-0)
3 files modified
debian/changelog (+8/-0)
debian/patches/1003-Fixing-the-find_loop_by_file-function-to-properly.patch (+30/-0)
debian/patches/series (+1/-0)
To merge this branch: bzr merge lp:~niedbalski/ubuntu/wily/multipath-tools/fix-lp-1469143
Reviewer Review Type Date Requested Status
Mathieu Trudel-Lapierre Disapprove
Chris J Arges Needs Resubmitting
Review via email: mp+263161@code.launchpad.net

Description of the change

Fixes LP: #1469143

To post a comment you must log in.
56. By Jorge Niedbalski

Adjusted unreleased to wily

Revision history for this message
Chris J Arges (arges) :
review: Approve
Revision history for this message
Chris J Arges (arges) wrote :

FYI, this should wait until 0.5.0 is released then add this on top.

Revision history for this message
Chris J Arges (arges) :
review: Needs Resubmitting
Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

We have 0.5.0 in wily now, are you still interested in doing this fix? If so, could you please update this merge or provide an updated debdiff on the bug?

review: Needs Information
Revision history for this message
Mathieu Trudel-Lapierre (cyphermox) wrote :

So I sponsored a fix for this which seemed more solid already; closing as Rejected.

As expressed on the bug, one of the issues with the fix here is that the loopback name is too short in some cases to convey the necessary information, it is better to map it by inode.

review: Disapprove

Unmerged revisions

56. By Jorge Niedbalski

Adjusted unreleased to wily

55. By Jorge Niedbalski

d/p/1003-Fixing-the-find_loop_by_file-function-to-properly.patch:
Fixing the find_loop_by_file function to properly compare
the filename by respecting the LO_NAME_SIZE. (LP: #1469143).

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2015-04-13 09:23:29 +0000
3+++ debian/changelog 2015-06-26 19:34:20 +0000
4@@ -1,3 +1,11 @@
5+multipath-tools (0.4.9-3ubuntu13) wily; urgency=medium
6+
7+ * d/p/1003-Fixing-the-find_loop_by_file-function-to-properly.patch:
8+ Fixing the find_loop_by_file function to properly compare
9+ the filename by respecting the LO_NAME_SIZE. (LP: #1469143).
10+
11+ -- Jorge Niedbalski <jorge.niedbalski@canonical.com> Fri, 26 Jun 2015 16:21:48 -0300
12+
13 multipath-tools (0.4.9-3ubuntu12) vivid; urgency=medium
14
15 [ Mauricio Faria de Oliveira ]
16
17=== added file 'debian/patches/1003-Fixing-the-find_loop_by_file-function-to-properly.patch'
18--- debian/patches/1003-Fixing-the-find_loop_by_file-function-to-properly.patch 1970-01-01 00:00:00 +0000
19+++ debian/patches/1003-Fixing-the-find_loop_by_file-function-to-properly.patch 2015-06-26 19:34:20 +0000
20@@ -0,0 +1,30 @@
21+From ae917cfc9504e613f59929fd680eb111c8eca8d0 Mon Sep 17 00:00:00 2001
22+From: Jorge Niedbalski <jorge.niedbalski@canonical.com>
23+Date: Fri, 26 Jun 2015 15:59:25 -0300
24+Subject: [PATCH] Fixing the find_loop_by_file function to properly compare the
25+ filename by respecting the LO_NAME_SIZE.
26+To: dm-devel@redhat.com
27+
28+This fixes the bug reported on https://bugs.launchpad.net/ubuntu/+source/multipath-tools/+bug/1469143
29+
30+Signed-off-by: Jorge Niedbalski <jorge.niedbalski@canonical.com>
31+---
32+ kpartx/lopart.c | 2 +-
33+ 1 file changed, 1 insertion(+), 1 deletion(-)
34+
35+diff --git a/kpartx/lopart.c b/kpartx/lopart.c
36+index 6f83048..e92aeed 100644
37+--- a/kpartx/lopart.c
38++++ b/kpartx/lopart.c
39+@@ -123,7 +123,7 @@ find_loop_by_file (const char * filename)
40+ continue;
41+ }
42+
43+- if (0 == strcmp(filename, loopinfo.lo_name)) {
44++ if (0 == strncmp(filename, loopinfo.lo_name, strlen(loopinfo.lo_name))) {
45+ close (fd);
46+ return xstrdup(dev); /*found */
47+ }
48+--
49+2.1.4
50+
51
52=== modified file 'debian/patches/series'
53--- debian/patches/series 2015-04-13 09:23:29 +0000
54+++ debian/patches/series 2015-06-26 19:34:20 +0000
55@@ -19,3 +19,4 @@
56 0016-kpartx-non-512B-GPT.patch
57 0017-kpartx-non-512B-sectors.patch
58 0018-ext-part-gt-512B-sectors.patch
59+1003-Fixing-the-find_loop_by_file-function-to-properly.patch

Subscribers

People subscribed via source and target branches