diff options
Diffstat (limited to 'debian/patches')
-rw-r--r-- | debian/patches/fix-rootfs-snapshot.patch | 15 | ||||
-rw-r--r-- | debian/patches/series | 1 |
2 files changed, 16 insertions, 0 deletions
diff --git a/debian/patches/fix-rootfs-snapshot.patch b/debian/patches/fix-rootfs-snapshot.patch new file mode 100644 index 00000000..02247a44 --- /dev/null +++ b/debian/patches/fix-rootfs-snapshot.patch @@ -0,0 +1,15 @@ +Description: Fix taking snapshots of '/' itself +Bug: https://github.com/kdave/btrfs-progs/issues/162 +Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=920886 + +--- a/utils.c ++++ b/utils.c +@@ -2079,7 +2079,7 @@ int find_mount_root(const char *path, ch + while ((ent = getmntent(mnttab))) { + len = strlen(ent->mnt_dir); + if (strncmp(ent->mnt_dir, path, len) == 0 && +- (path[len] == '/' || path[len] == '\0')) { ++ (len == 1 || path[len] == '/' || path[len] == '\0')) { + /* match found and use the latest match */ + if (longest_matchlen <= len) { + free(longest_match); diff --git a/debian/patches/series b/debian/patches/series index c010bd16..d3a965aa 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -1 +1,2 @@ python3-use-deb-layout.patch +fix-rootfs-snapshot.patch |