threads / patch / 31342

patch, 2 partsIgnore trailing slash in mkdir() on platforms that can't deal with this

Subject: [PATCH 2/2] Ignore trailing slash in mkdir() on platforms that can't deal with this

## tl;dr

One message between Aug 24, 2012 and Aug 24, 2012. Diffs are folded; open one to read it.

replies: 0people: 1as markdown or json

Joachim Schmitz· Aug 24, 2012, 10:32 UTC · lore
Signed-off-by: Joachim Schmitz <jojo@schmitz-digital.de>
---
 git-compat-util.h | 5 +++++
 1 file changed, 5 insertions(+)
Show changes to git-compat-util.h +5 −0
diff --git a/git-compat-util.h b/git-compat-util.h
index 35b095e..34f040f 100644
--- a/git-compat-util.h
+++ b/git-compat-util.h
@@ -162,6 +162,11 @@
 #define probe_utf8_pathname_composition(a,b)
 #endif
 
+#ifdef MKDIR_WO_TRAILING_SLASH
+#define mkdir(a,b) compat_mkdir_wo_trailing_slash((a),(b))
+extern int compat_mkdir_wo_trailing_slash(const char*, mode_t);
+#endif
+
 #ifndef NO_LIBGEN_H
 #include <libgen.h>
 #else
-- 
1.7.12

← back to recent threads