From 192938a19a20317d3347f4f941b1234d67fa43d1 Mon Sep 17 00:00:00 2001 From: RAJEEV RANJAN Date: Wed, 30 Nov 2011 00:16:36 +0000 Subject: [PATCH] elementary/quicklaunch - [E-devel] [Patch] quicklaunch patch a. Fix to handle the condition when read returns 0 and the content of buf is uninitialized in function handle_run inside file "src/bin/quicklaunch.c". b. Indentation correction in function handle_run around the location of fix above. Signed-Off-By: RAJEEV RANJAN Signed-Off-By: PRINCE KUMAR DUBEY Signed-Off-By: ChunEon Park SVN revision: 65699 --- legacy/elementary/src/bin/quicklaunch.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/legacy/elementary/src/bin/quicklaunch.c b/legacy/elementary/src/bin/quicklaunch.c index 50f26ec42e..fd1ed7c047 100644 --- a/legacy/elementary/src/bin/quicklaunch.c +++ b/legacy/elementary/src/bin/quicklaunch.c @@ -95,10 +95,10 @@ handle_run(int fd, unsigned long bytes) int argc; buf = alloca(bytes); - if (read(fd, buf, bytes) < 0) + if (read(fd, buf, bytes) <= 0) { - close(fd); - return; + close(fd); + return; } close(fd); argc = ((unsigned long *)(buf))[0];