aboutsummaryrefslogtreecommitdiffstats
path: root/package/utils/ubi-utils/patches/010-fix-rpmatch.patch
diff options
context:
space:
mode:
authorJohn Crispin <john@openwrt.org>2014-04-03 14:26:42 +0000
committerJohn Crispin <john@openwrt.org>2014-04-03 14:26:42 +0000
commit08b49244014c1349278c9df3a61c124acecd31ae (patch)
tree8c042bd62fc2af4dc4f96e11e22306abadcf0323 /package/utils/ubi-utils/patches/010-fix-rpmatch.patch
parent69519ed75f91539b16fdcd6bec2f4deb5805d856 (diff)
downloadupstream-08b49244014c1349278c9df3a61c124acecd31ae.tar.gz
upstream-08b49244014c1349278c9df3a61c124acecd31ae.tar.bz2
upstream-08b49244014c1349278c9df3a61c124acecd31ae.zip
ubi-utils: mini version of mtd-utils that only includes ubi tools
Signed-off-by: John Crispin <blogic@openwrt.org> SVN-Revision: 40367
Diffstat (limited to 'package/utils/ubi-utils/patches/010-fix-rpmatch.patch')
-rw-r--r--package/utils/ubi-utils/patches/010-fix-rpmatch.patch19
1 files changed, 19 insertions, 0 deletions
diff --git a/package/utils/ubi-utils/patches/010-fix-rpmatch.patch b/package/utils/ubi-utils/patches/010-fix-rpmatch.patch
new file mode 100644
index 0000000000..4a04676b49
--- /dev/null
+++ b/package/utils/ubi-utils/patches/010-fix-rpmatch.patch
@@ -0,0 +1,19 @@
+--- a/include/common.h
++++ b/include/common.h
+@@ -122,10 +122,12 @@
+ }
+
+ if (strcmp("\n", line) != 0) {
+- switch (rpmatch(line)) {
+- case 0: ret = false; break;
+- case 1: ret = true; break;
+- case -1:
++ switch (line[0]) {
++ case 'N':
++ case 'n': ret = false; break;
++ case 'Y':
++ case 'y': ret = true; break;
++ default:
+ puts("unknown response; please try again");
+ continue;
+ }