emuld : reduce buffer size to send to guest server
authorDaiYoung Kim <daiyoung777.kim@samsung.com>
Sat, 27 Apr 2013 10:39:25 +0000 (19:39 +0900)
committerDaiYoung Kim <daiyoung777.kim@samsung.com>
Sat, 27 Apr 2013 10:39:25 +0000 (19:39 +0900)
Signed-off-by: DaiYoung, Kim <daiyoung777.kim@samsung.com>
packaging/emuld.spec
src/emuld.c

index e666bc4d7b72fb498f60cdb4c8742a214cab3538..716166c741e017b81d7b60aa0ffeb1f6107b8248 100755 (executable)
@@ -1,6 +1,6 @@
 #git:/slp/pkgs/e/emulator-daemon
 Name: emuld
-Version: 0.2.36
+Version: 0.2.37
 Release: 1
 Summary: emuld is used for communication emulator between and ide.
 License: Apache
index 6ddafae4f353c4721483edd3cf9958bd93c7adc9..3a554cb6068a49da691be42e3e5c56b5b7a0ea3c 100755 (executable)
@@ -1304,7 +1304,7 @@ void send_guest_server(char* databuf)
                return;
        }
 
-       char buf[64];
+       char buf[32];
        struct sockaddr_in si_other;
        int s, slen=sizeof(si_other);
        FILE* fd;
@@ -1338,7 +1338,7 @@ void send_guest_server(char* databuf)
        }
 
        memset(buf, '\0', sizeof(buf));
-       snprintf(buf, 60, "4\n%s", databuf);
+       snprintf(buf, sizeof(buf), "4\n%s", databuf);
 
        LOG("sendGuestServer msg: %s", buf);
        if(sendto(s, buf, sizeof(buf), 0, (struct sockaddr*)&si_other, slen) == -1)