merge-index: fix longstanding bug in merging symlinks