aboutsummaryrefslogtreecommitdiffstats
path: root/main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2017-11-28 16:16:03 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2017-11-28 16:16:03 +0000
commit0c1064dd88d91662b81862556556cee9f807abde (patch)
tree1f8047ba0892707ea4c3c67ba4de140007c0d3eb /main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch
parentc29bf7e28f2115166449d6a5d4feb66feb83f4e1 (diff)
downloadaports-0c1064dd88d91662b81862556556cee9f807abde.tar.gz
aports-0c1064dd88d91662b81862556556cee9f807abde.tar.bz2
aports-0c1064dd88d91662b81862556556cee9f807abde.tar.xz
main/busybox: fix patch for fsck
Diffstat (limited to 'main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch')
-rw-r--r--main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch45
1 files changed, 36 insertions, 9 deletions
diff --git a/main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch b/main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch
index 323e079021..31d8e3f89d 100644
--- a/main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch
+++ b/main/busybox/0001-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch
@@ -1,14 +1,14 @@
-From 549b5fa1384bb29c3ea92486539dccd9a7d71b83 Mon Sep 17 00:00:00 2001
+From 54f76ba53e22fdbc9efebe8b42dd121ec3126fef Mon Sep 17 00:00:00 2001
From: Natanael Copa <ncopa@alpinelinux.org>
Date: Tue, 28 Nov 2017 13:23:17 +0100
Subject: [PATCH] fsck: resolve LABEL=.../UUID=... spec to device
---
- e2fsprogs/fsck.c | 2 ++
- 1 file changed, 2 insertions(+)
+ e2fsprogs/fsck.c | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/e2fsprogs/fsck.c b/e2fsprogs/fsck.c
-index eb53002b1..2adf0cf07 100644
+index eb53002b1..338701c6a 100644
--- a/e2fsprogs/fsck.c
+++ b/e2fsprogs/fsck.c
@@ -60,6 +60,7 @@
@@ -19,14 +19,41 @@ index eb53002b1..2adf0cf07 100644
#include "common_bufsiz.h"
/* "progress indicator" code is somewhat buggy and ext[23] specific.
-@@ -976,6 +977,7 @@ int fsck_main(int argc UNUSED_PARAM, char **argv)
- // "/path", "UUID=xxx" or "LABEL=xxx" into block device name
- // ("UUID=xxx"/"LABEL=xxx" can probably shifted to fsck.auto duties)
+@@ -523,12 +524,13 @@ static int wait_many(int flags)
+ * Execute a particular fsck program, and link it into the list of
+ * child processes we are waiting for.
+ */
+-static void execute(const char *type, const char *device,
++static void execute(const char *type, const char *spec,
+ const char *mntpt /*, int interactive */)
+ {
+ int i;
+ struct fsck_instance *inst;
+ pid_t pid;
++ char *device = (char *)spec;
+
+ G.args[0] = xasprintf("fsck.%s", type);
+
+@@ -543,7 +545,8 @@ static void execute(const char *type, const char *device,
+ }
+ #endif
+
+- G.args[G.num_args - 2] = (char*)device;
++ resolve_mount_spec(&device);
++ G.args[G.num_args - 2] = device;
+ /* G.args[G.num_args - 1] = NULL; - already is */
+
+ if (G.verbose || G.noexecute) {
+@@ -972,9 +975,6 @@ int fsck_main(int argc UNUSED_PARAM, char **argv)
+
+ /* "/dev/blk" or "/path" or "UUID=xxx" or "LABEL=xxx" */
+ if ((arg[0] == '/' && !opts_for_fsck) || strchr(arg, '=')) {
+-// FIXME: must check that arg is a blkdev, or resolve
+-// "/path", "UUID=xxx" or "LABEL=xxx" into block device name
+-// ("UUID=xxx"/"LABEL=xxx" can probably shifted to fsck.auto duties)
devices = xrealloc_vector(devices, 2, num_devices);
-+ resolve_mount_spec(&arg);
devices[num_devices++] = arg;
continue;
- }
--
2.15.0