* create url files instead links in startup menu
[fw/sdcc] / support / Util / MySystem.c
index b735cd640f4ad34ec6cef5e12a785f3eee9cef80..6aec20f98e91b338e1592926bab4441e115cfcec 100644 (file)
@@ -243,16 +243,13 @@ merge_command(const char *command, const char *params)
 
 
 /*!
- * check if the path is absolute
+ * check if the path is relative or absolute (if contains the dir separator)
  */
 
 static int
 has_path(const char *path)
 {
-  if (strrchr(path, DIR_SEPARATOR_CHAR) == NULL)
-      return 0;
-
-  return 1;
+  return dbuf_splitPath(path, NULL, NULL);
 }
 
 
@@ -324,6 +321,11 @@ my_system(const char *cmd)
   }
 
   e = system(cmdLine);
+
+  if (options.verboseExec && e) {
+      printf("+ %s returned errorcode %d\n", cmdLine, e);
+  }
+
   Safe_free(cmdLine);
 
   return e;