]> git.ipfire.org Git - thirdparty/git.git/blobdiff - exec_cmd.c
grep: search history of moved submodules
[thirdparty/git.git] / exec_cmd.c
index 9d5703a157fe8e9d8396e0771798e54dc5eea6eb..19ac2146d0c49be8f5ef3739664dc3105544b4c2 100644 (file)
@@ -38,21 +38,17 @@ char *system_path(const char *path)
        return strbuf_detach(&d, NULL);
 }
 
-const char *git_extract_argv0_path(const char *argv0)
+void git_extract_argv0_path(const char *argv0)
 {
        const char *slash;
 
        if (!argv0 || !*argv0)
-               return NULL;
+               return;
 
        slash = find_last_dir_sep(argv0);
 
-       if (slash) {
+       if (slash)
                argv0_path = xstrndup(argv0, slash - argv0);
-               return slash + 1;
-       }
-
-       return argv0;
 }
 
 void git_set_argv_exec_path(const char *exec_path)