Thomas Wolf
26832a00e4
Fix symlink content comparison on MacOS in tree walk
Symlinks on MacOS are written as UTF-8 NFD, but readSymbolicLink().toString() converts to NFC with potentially fewer bytes. May occur in particular if the link target has non-ASCII characters for which the NFC and NFD encodings differ. This may lead to an EOFException: Short read of block. This causes all kinds of weird effects in EGit, ranging from failing rebases (which report the exception to the user) to EGit decorations in the navigator silently disappearing (and never coming back). * Rename readContentAsNormalizedString() to readSymlinkTarget() as it's called only for symlinks. Also make it protected. * Fix by allowing the read to succeed even if less than the expected number of bytes are returned by the entry's input stream. * Override in FileTreeIterator to use fs.readSymlink() directly. Includes a new MacOS-only test. Change-Id: I264c5972d67b1cbb1ed690580f5706e671b9affd Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com> |
8 anos atrás | |
---|---|---|
.. | ||
diff | Allow setting FileMode to executable when applying patches in ApplyCommand | 8 anos atrás |
indexdiff | Fix symlink content comparison on MacOS in tree walk | 7 anos atrás |
nls | Fix TestTranslationBundle | 13 anos atrás |
patch | Initial JGit contribution to eclipse.org | 14 anos atrás |
test/resources | Fix ArrayIndexOutOfBoundsException in DirCacheIterator | 13 anos atrás |