Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Kill "if" before free, and useless cast of free argument.
[simgrid.git] / src / gras / Virtu / process.c
index c0cf02f..36949b3 100644 (file)
@@ -179,8 +179,7 @@ void gras_procdata_exit()
 const char *gras_os_hostport()
 {
   static char *res = NULL;
-  if (res)
-    free(res);                  /* my port may have changed */
+  free(res);                  /* my port may have changed */
   res = bprintf("%s:%d", gras_os_myname(), gras_os_myport());
   return (const char *) res;
 }