Web lists-archives.com

Re: Cygwin Git with Windows paths

On Tue, Nov 20, 2018 at 4:36 AM Torsten Bögershausen wrote:
> Could you please post a "git diff" of your instrumented code,
> so that I/we can follow the debugging, especially what the printouts mean?
> I think we need to understand what is going on in abspath.c

diff --git a/abspath.c b/abspath.c
index 9857985..09548e5 100644
--- a/abspath.c
+++ b/abspath.c
@@ -14,6 +14,7 @@ int is_directory(const char *path)
 /* removes the last path component from 'path' except if 'path' is root */
 static void strip_last_component(struct strbuf *path)
+       printf("strip_last_component, path, [%s]\n", path->buf);
        size_t offset = offset_1st_component(path->buf);
        size_t len = path->len;

@@ -30,6 +31,8 @@ static void strip_last_component(struct strbuf *path)
 /* get (and remove) the next component in 'remaining' and place it in 'next' */
 static void get_next_component(struct strbuf *next, struct strbuf *remaining)
+       printf("get_next_component, next, [%s]\n", next->buf);
+       printf("get_next_component, remaining, [%s]\n", remaining->buf);
        char *start = NULL;
        char *end = NULL;