Thread (2 messages) flat view 2 messages, 2 authors, 2016-06-15

git difftool --dir-diff error in the presence of symlinks to directories

From: Ismail Badawi <hidden>
Date: 2016-06-15 23:05:21

Reproduce like this (using git 2.4.3):

git init
mkdir foo
touch foo/bar
git add .
git commit -m "Initial commit."
ln -s foo link
git add .
git commit -m "Add link to foo."
git difftool -d HEAD^ HEAD

That last command outputs:

fatal: Unable to hash /Users/isbadawi/test/link
hash-object /Users/isbadawi/test/link: command returned error: 128

Briefly looking at the 'git difftool' source it looks like it uses the
output of 'git diff --raw' and calls 'hash-object' on any object whose
mode is nonzero, including symlinks.

I'm not sure what the right thing to do here is -- just thought I'd
report this failure.

Thanks,
Ismail
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help