mirror of
https://github.com/samba-team/samba.git
synced 2025-01-11 05:18:09 +03:00
ctdb-util: Fix warning about ignored result from system()
Signed-off-by: Martin Schwenke <martin@meltin.net> Reviewed-by: Amitay Isaacs <amitay@gmail.com>
This commit is contained in:
parent
c1558adeaa
commit
2807b185f4
@ -73,7 +73,7 @@ void ctdb_die(struct ctdb_context *ctdb, const char *msg)
|
||||
*/
|
||||
void ctdb_external_trace(void)
|
||||
{
|
||||
|
||||
int ret;
|
||||
const char * t = getenv("CTDB_EXTERNAL_TRACE");
|
||||
char * cmd;
|
||||
|
||||
@ -83,7 +83,11 @@ void ctdb_external_trace(void)
|
||||
|
||||
cmd = talloc_asprintf(NULL, "%s %lu", t, (unsigned long) getpid());
|
||||
DEBUG(DEBUG_WARNING,("begin external trace: %s\n", cmd));
|
||||
system(cmd);
|
||||
ret = system(cmd);
|
||||
if (ret == -1) {
|
||||
DEBUG(DEBUG_ERR,
|
||||
("external trace command \"%s\" failed\n", cmd));
|
||||
}
|
||||
DEBUG(DEBUG_WARNING,("end external trace: %s\n", cmd));
|
||||
talloc_free(cmd);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user