Commit 64d47ad9 authored by Pablo Barciela's avatar Pablo Barciela

gs-lock-plug.c: Fix build warning:

ignoring return value of ‘fscanf’, declared with attribute warn_unused_result
parent 663b2f1e
......@@ -190,7 +190,10 @@ process_is_running (const char * name)
int num_processes;
gchar *command = g_strdup_printf ("pidof %s | wc -l", name);
FILE *fp = popen(command, "r");
fscanf(fp, "%d", &num_processes);
if (fscanf(fp, "%d", &num_processes) != 1)
num_processes = 0;
g_free (command);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment