summaryrefslogtreecommitdiff
path: root/util-linux
diff options
context:
space:
mode:
authorDenys Vlasenko2014-09-08 18:19:15 +0200
committerDenys Vlasenko2014-09-08 18:19:15 +0200
commit26a8b9f1967d910033c516462c101100e041a9b4 (patch)
tree14e5a8fa265edc5736457bf069627e74dbc74ebd /util-linux
parent07f7ea70edd0fdc7ad7da36df3f487111e14d0d1 (diff)
downloadbusybox-26a8b9f1967d910033c516462c101100e041a9b4.zip
busybox-26a8b9f1967d910033c516462c101100e041a9b4.tar.gz
mdev: treat zero-length /dev/mdev.seq the same as "\n" one. Closes 7334
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'util-linux')
-rw-r--r--util-linux/mdev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/util-linux/mdev.c b/util-linux/mdev.c
index e80b58f..b2d5657 100644
--- a/util-linux/mdev.c
+++ b/util-linux/mdev.c
@@ -972,7 +972,7 @@ wait_for_seqfile(const char *seq)
break;
}
seqbuf[seqlen] = '\0';
- if (seqbuf[0] == '\n') {
+ if (seqbuf[0] == '\n' || seqbuf[0] == '\0') {
/* seed file: write out seq ASAP */
xwrite_str(seq_fd, seq);
xlseek(seq_fd, 0, SEEK_SET);