Aaron Marcher пре 7 година
родитељ
комит
f007007156
1 измењених фајлова са 1 додато и 2 уклоњено
  1. 1 2
      components/run_command.c

+ 1 - 2
components/run_command.c

@@ -11,8 +11,7 @@ run_command(const char *cmd)
 	char *p;
 	FILE *fp;
 
-	fp = popen(cmd, "r");
-	if (fp == NULL) {
+	if (!(fp = popen(cmd, "r"))) {
 		fprintf(stderr, "popen '%s': %s\n", cmd, strerror(errno));
 		return NULL;
 	}