diff options
Diffstat (limited to 'meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc/ubiformat.c.patch')
-rw-r--r-- | meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc/ubiformat.c.patch | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc/ubiformat.c.patch b/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc/ubiformat.c.patch new file mode 100644 index 000000000..d21ed577b --- /dev/null +++ b/meta-initramfs/recipes-devtools/mtd/ubi-utils-klibc/ubiformat.c.patch | |||
@@ -0,0 +1,20 @@ | |||
1 | --- a/ubi-utils/ubiformat.c 2012-05-03 01:14:39.000000000 +0200 | ||
2 | +++ b/ubi-utils/ubiformat.c 2012-05-20 23:11:57.000000000 +0200 | ||
3 | @@ -246,7 +246,7 @@ | ||
4 | |||
5 | while (1) { | ||
6 | normsg_cont("continue? (yes/no) "); | ||
7 | - if (scanf("%3s", buf) == EOF) { | ||
8 | + if (fgets(buf,4,stdin) == NULL) { | ||
9 | sys_errmsg("scanf returned unexpected EOF, assume \"yes\""); | ||
10 | return 1; | ||
11 | } | ||
12 | @@ -262,7 +262,7 @@ | ||
13 | char buf[4]; | ||
14 | |||
15 | while (1) { | ||
16 | - if (scanf("%3s", buf) == EOF) { | ||
17 | + if (fgets(buf,4,stdin) == NULL) { | ||
18 | sys_errmsg("scanf returned unexpected EOF, assume \"no\""); | ||
19 | return 0; | ||
20 | } | ||