projects
/
platform
/
upstream
/
multipath-tools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
00886e0
)
[multipathd] don't care interpreting "\n" as a cli command
author
Christophe Varoqui
<root@xa-s05.(none)>
Fri, 11 Nov 2005 12:48:42 +0000
(13:48 +0100)
committer
Christophe Varoqui
<root@xa-s05.(none)>
Fri, 11 Nov 2005 12:48:42 +0000
(13:48 +0100)
CR epileptics like me are happier now.
multipathd>
multipathd>
multipathd>
multipathd>
multipathd>
multipathd>
multipathd>
multipathd/uxclnt.c
patch
|
blob
|
history
diff --git
a/multipathd/uxclnt.c
b/multipathd/uxclnt.c
index
bb08a8a
..
47d528c
100644
(file)
--- a/
multipathd/uxclnt.c
+++ b/
multipathd/uxclnt.c
@@
-25,8
+25,14
@@
static void process(int fd)
while ((line = readline("multipathd> "))) {
size_t len;
+ size_t llen = strlen(line);
- if (send_packet(fd, line, strlen(line) + 1) != 0) break;
+ if (!llen) {
+ free(line);
+ continue;
+ }
+
+ if (send_packet(fd, line, llen + 1) != 0) break;
if (recv_packet(fd, &reply, &len) != 0) break;
printf("%s", reply);