Re: 'git grep needle rev' attempts to access 'rev:.../.gitattributes' in the worktree
- From
Nguyen Thai Ngoc Duy <pclouds@gmail.com>
- Date
- Oct 9, 2012, 09:38 UTC
- Message-ID
- <CACsJy8BFmUr5_E47900T6j9Lgdvj96_dNbo2LHP5hLYq3w7ZLA@mail.gmail.com>
- In-Reply-To
- <5073E87D.9020100@viscovery.net>
On Tue, Oct 9, 2012 at 4:03 PM, Johannes Sixt <j.sixt@viscovery.net> wrote:
Show 5 quoted lines
> Running 'git grep needle origin/master' on Windows gives numerous warnings > of the kind > > warning: unable to access 'origin/master:Documentation/.gitattributes': > Invalid argument
strace confirms it. Stack trace
#0 read_attr_from_file (path=0x820e818 "HEAD:Documentation/.gitattributes", macro_ok=0) at attr.c:351 #1 0x080d378d in read_attr (path=0x820e818 "HEAD:Documentation/.gitattributes", macro_ok=0) at attr.c:436 #2 0x080d3bf1 in prepare_attr_stack (path=0x820e7f0 "HEAD:Documentation/.gitattributes") at attr.c:630 #3 0x080d3f68 in collect_all_attrs (path=0x820e7f0 "HEAD:Documentation/.gitattributes") at attr.c:747 #4 0x080d3ffd in git_check_attr (path=0x820e7f0 "HEAD:Documentation/.gitattributes", num=1, check=0xbfffd848) at attr.c:761 #5 0x0815e736 in userdiff_find_by_path (path=0x820e7f0 "HEAD:Documentation/.gitattributes") at userdiff.c:278 #6 0x081058ca in grep_source_load_driver (gs=0xbfffd978) at grep.c:1504 #7 0x08105907 in grep_source_is_binary (gs=0xbfffd978) at grep.c:1512 #8 0x08104eaa in grep_source_1 (opt=0xbfffe304, gs=0xbfffd978, collect_hits=0) at grep.c:1180
Never touched userdiff.c before. Anybody?
-- Duy