Merge branch 'sb/branch-avoid-repeated-strbuf-release'
[gitweb.git] / path.c
diff --git a/path.c b/path.c
index 883324b10a978c9815cfe2dc66c7539b33d280dd..00ec04e7a5f9e90b758855a16f420324ee158739 100644 (file)
--- a/path.c
+++ b/path.c
@@ -9,6 +9,7 @@
 #include "worktree.h"
 #include "submodule-config.h"
 #include "path.h"
+#include "packfile.h"
 
 static int get_st_mode_bits(const char *path, int *mode)
 {
@@ -717,7 +718,7 @@ char *expand_user_path(const char *path, int real_home)
                        if (!home)
                                goto return_null;
                        if (real_home)
-                               strbuf_addstr(&user_path, real_path(home));
+                               strbuf_add_real_path(&user_path, home);
                        else
                                strbuf_addstr(&user_path, home);
 #ifdef GIT_WINDOWS_NATIVE