Explorar el Código

Also avoid displaying heat results if DISPLAY is empty

Samuel Thibault hace 6 años
padre
commit
0409614344
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      examples/heat/heat.c

+ 2 - 1
examples/heat/heat.c

@@ -804,7 +804,8 @@ int main(int argc, char **argv)
 	}
 
 #ifdef STARPU_OPENGL_RENDER
-	if (getenv("DISPLAY"))
+	const char *display = getenv("DISPLAY");
+	if (display && display[0])
 		opengl_render(ntheta, nthick, result, pmesh, argc, argv);
 #endif