Change-Id: I6f1fa2789b42be00acddc30524cb78cfafece6e9
Signed-off-by: Nishant Chaprana <n.chaprana@samsung.com>
Name: inm-manager
Summary: INM(Intelligent Network Monitoring) daemon
-Version: 0.0.23
+Version: 0.0.24
Release: 1
Group: Network & Connectivity/Other
License: Apache-2.0
errno = 0;
n = read(fd, buf, 1024);
-
- buf[n - 1] = '\0'; /* remove new line... */
- if (n == 0)
+ if (n == 0) {
printf("Error: read() from stdin returns 0.\n");
- else if (n < 0)
+ } else if (n < 0) {
printf("input: read, err\n");
- else
+ } else {
+ buf[n - 1] = '\0'; /* remove new line... */
printf("\n\n");
+ process_input(buf, user_data);
+ }
- process_input(buf, user_data);
return TRUE;
}