deprecated gets() -> fgets()
This commit is contained in:
parent
85e0a08cff
commit
53613f4e69
|
|
@ -45,7 +45,10 @@ Ipc_Status_t ipc_transport_get_line (
|
||||||
NG_IGNORE(wait);
|
NG_IGNORE(wait);
|
||||||
|
|
||||||
printf ("GET_LINE\n");
|
printf ("GET_LINE\n");
|
||||||
gets (str);
|
fgets (str, 512, stdin);
|
||||||
|
char *tmp = strchr(str, '\n');
|
||||||
|
if (tmp)
|
||||||
|
*tmp = '\0';
|
||||||
*len = (int) strlen (str);
|
*len = (int) strlen (str);
|
||||||
return IPC_STATUS_OK;
|
return IPC_STATUS_OK;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue