fixes bug #1595324 in sf.net bugtracker

This commit is contained in:
ilsimo 2007-03-25 14:57:08 +00:00
parent fd8ce33f59
commit 5d29a7127b

View File

@ -148,9 +148,11 @@ main(int argc, char** argv)
}
error = g_file_read(fd, pid_s, 7);
if (0 != error)
if (-1 == error)
{
g_printf("error reading pid file: %s\n", g_get_strerror());
g_file_close(fd);
g_exit(error);
}
g_file_close(fd);
pid = g_atoi(pid_s);