add bug: creating git annex unused fails when a filename contains newline

This commit is contained in:
zoltanp 2015-01-19 11:22:17 +00:00 committed by admin
parent ffe5418899
commit 274432021c

View file

@ -0,0 +1,65 @@
### Please describe the problem.
After annexing files with newline (`\n`) characters in their name, then running `git annex unused` on the same git annex repository fails, instead of working correctly. The error is "git-annex: unknown response from git cat-file ".
This issue might happen with filenames with other special characters in the filename, too.
### What steps will reproduce the problem?
1. create git annex repository
2. create a file with a newline in its name
3. annex the file
4. run `git annex unused`
Expected result: success
Actual results: error: "git-annex: unknown response from git cat-file ".
### What version of git-annex are you using? On what operating system?
git-annex package version 5.20140412ubuntu1, architecture i386. System is xubuntu 14.04.
[[!format sh """
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex$ git annex version
git-annex version: 5.20140412ubuntu1
build flags: Assistant Webapp Webapp-secure Pairing Testsuite S3 WebDAV Inotify DBus DesktopNotify XMPP DNS Feeds Quvi TDFA CryptoHash
key/value backends: SHA256E SHA1E SHA512E SHA224E SHA384E SKEIN256E SKEIN512E SHA256 SHA1 SHA512 SHA224 SHA384 SKEIN256 SKEIN512 WORM URL
remote types: git gcrypt S3 bup directory rsync web webdav tahoe glacier hook external
local repository version: 5
supported repository version: 5
upgrade supported from repository versions: 0 1 2 4
"""]]
### Please provide any additional information below.
[[!format sh """
# If you can, paste a complete transcript of the problem occurring here.
# If the problem is with the git-annex assistant, paste in .git/annex/daemon.log
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex$ git annex unused
unused . (checking for unused data...) [2014-07-13 16:42:04 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","ls-files","--cached","--others","-z","--","/media/zolee/Stuff/dell-zoli-git-annex"]
[2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","symbolic-ref","HEAD"]
[2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref","--hash","refs/heads/dell-zoli-master"]
[2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref"]
(checking dell-zoli-master...) [2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref","--head"]
[2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref","--head"]
[2014-07-13 16:42:31 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","diff-index","-z","--raw","--no-renames","-l0","refs/heads/dell-zoli-master"]
(checking store-zoli/laptop-zoli-master...) [2014-07-13 16:42:32 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref","--head"]
[2014-07-13 16:42:32 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","show-ref","--head"]
[2014-07-13 16:42:32 EEST] read: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","diff-index","-z","--raw","--no-renames","-l0","refs/remotes/store-zoli/laptop-zoli-master"]
[2014-07-13 16:42:33 EEST] chat: git ["--git-dir=/media/zolee/Stuff/dell-zoli-git-annex/.git","--work-tree=/media/zolee/Stuff/dell-zoli-git-annex","cat-file","--batch"]
git-annex: unknown response from git cat-file ("Code Composer Studio missing","refs/remotes/store-zoli/laptop-zoli-master:egyetem/2009-2010-sem2/diploma/tex/titlu-lucrare.tex~")
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex$
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex/egyetem/2009-2010-sem2/media-processors$ ls
51325409-1.pdf course2010 Noterestanta.pdf Proiecte_6xxx.pdf rg_rand.c TMS320C6000?Code Composer Studio? Tutorial?- spru301c.pdf
ccs_workspace.tar.gz netrol Proc_Media project site
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex/egyetem/2009-2010-sem2/media-processors$ ls -b
51325409-1.pdf course2010 Noterestanta.pdf Proiecte_6xxx.pdf rg_rand.c \ \ \ TMS320C6000\nCode\ Composer\ Studio\n\ \ \ \ \ \ Tutorial\n-\ spru301c.pdf
ccs_workspace.tar.gz netrol Proc_Media project site
zolee@zolee-Latitude-E6440:/media/zolee/Stuff/dell-zoli-git-annex/egyetem/2009-2010-sem2/media-processors$
# End of transcript or log.
"""]]