chiark / gitweb /
path-util: no need to check whether p is absolute twice
authorLennart Poettering <lennart@poettering.net>
Fri, 12 Dec 2014 01:35:14 +0000 (02:35 +0100)
committerLennart Poettering <lennart@poettering.net>
Fri, 12 Dec 2014 12:35:32 +0000 (13:35 +0100)
src/shared/path-util.c

index be03695..b3fe0b8 100644 (file)
@@ -129,7 +129,7 @@ char *path_make_absolute_cwd(const char *p) {
         if (!cwd)
                 return NULL;
 
-        return path_make_absolute(p, cwd);
+        return strjoin(cwd, "/", p, NULL);
 }
 
 int path_make_relative(const char *from_dir, const char *to_path, char **_r) {