{"thread":{"id":"22439","subject":"v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","startedAt":"2010-01-29T15:12:04Z","lastAt":"2010-01-31T19:21:11Z","messageCount":13,"participants":["Jonathan del Strother","Jens Lehmann","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"132962","messageId":"57518fd11001290712s2585e468o73b746b7ca27e1f1@mail.gmail.com","threadId":"22439","inReplyTo":null,"subject":"v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-29T15:12:04Z","receivedAt":"2010-01-29T15:12:04Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"Heya,\n\ngit-stash in v1.7.0-rc0 gives me several hundred lines of :\n\nerror: unable to find dd4a345a770f5c82a668932b7289f42b1ae38103\nerror: unable to find dd4a345a770f5c82a668932b7289f42b1ae38103\nerror: unable to find dd4a345a770f5c82a668932b7289f42b1ae38103\n....\nerror: unable to find 0dc67edc22017de22161dde93baa615767b9c6e0\nerror: unable to find 0dc67edc22017de22161dde93baa615767b9c6e0\nerror: unable to find 0dc67edc22017de22161dde93baa615767b9c6e0\nerror: unable to find 0dc67edc22017de22161dde93baa615767b9c6e0\n....\nerror: unable to find 980f084e71097df3d4086aaab574972321df80f2\nerror: unable to find 980f084e71097df3d4086aaab574972321df80f2\nerror: unable to find 980f084e71097df3d4086aaab574972321df80f2\nerror: unable to find 980f084e71097df3d4086aaab574972321df80f2\n\n\nOther than that, it appears to work fine.  'git show <sha1>' works too\n- they're all a bunch of file contents, with no particular pattern.\n\nThis only happens in my main (private) repo.  I can't seem to come up\nwith a reproducible example for anyone else...\n\nThe previous build I was using -\n5b15950ac414a8a2d4f5eb480712abcc9fe176d2 from Jan 19th - didn't show\nthis problem.  Want me to try and bisect further?\n\n\n-Jonathan\n"},{"id":"133052","messageId":"57518fd11001291646l5b0b581dm553689232b0910e8@mail.gmail.com","threadId":"22439","inReplyTo":"7vzl3wiz59.fsf@alter.siamese.dyndns.org","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-30T00:46:17Z","receivedAt":"2010-01-30T00:46:17Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"On 29 January 2010 17:44, Junio C Hamano <gitster@pobox.com> wrote:\n> Jonathan del Strother <maillist@steelskies.com> writes:\n>\n>> Heya,\n>>\n>> git-stash in v1.7.0-rc0 gives me several hundred lines of :\n>> The previous build I was using -\n>> 5b15950ac414a8a2d4f5eb480712abcc9fe176d2 from Jan 19th - didn't show\n>> this problem.  Want me to try and bisect further?\n>\n> Yes, please.\n>\n\nee6fc514f2df821c2719cc49499a56ef2fb136b0 (Show submodules as modified\nwhen they contain a dirty work tree) seems to be the first bad commit.\n"},{"id":"133112","messageId":"4B642696.2070501@web.de","threadId":"22439","inReplyTo":"57518fd11001291646l5b0b581dm553689232b0910e8@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jens Lehmann","fromEmail":"jens.lehmann@web.de","sentAt":"2010-01-30T12:31:18Z","receivedAt":"2010-01-30T12:31:18Z","isPatch":false,"sender":{"key":"jens.lehmann@web.de","avatar":"https://avatars.githubusercontent.com/u/135220?v=4"},"body":"Am 30.01.2010 01:46, schrieb Jonathan del Strother:\n> On 29 January 2010 17:44, Junio C Hamano <gitster@pobox.com> wrote:\n>> Jonathan del Strother <maillist@steelskies.com> writes:\n>>\n>>> Heya,\n>>>\n>>> git-stash in v1.7.0-rc0 gives me several hundred lines of :\n>>> The previous build I was using -\n>>> 5b15950ac414a8a2d4f5eb480712abcc9fe176d2 from Jan 19th - didn't show\n>>> this problem.  Want me to try and bisect further?\n>>\n>> Yes, please.\n>>\n> \n> ee6fc514f2df821c2719cc49499a56ef2fb136b0 (Show submodules as modified\n> when they contain a dirty work tree) seems to be the first bad commit.\n\nThanks for pinning that down.\n\nI assume you have one or more submodules, maybe even with untracked\nor yet uncommitted modified files in your tree? If so, what does git\nstatus say in the superproject and in the submodule(s)?\n\n(If you want to keep some information off the list, you can mail me\nprivately)\n"},{"id":"133113","messageId":"57518fd11001300523xf7d931by254581c8494171af@mail.gmail.com","threadId":"22439","inReplyTo":"4B642696.2070501@web.de","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-30T13:23:45Z","receivedAt":"2010-01-30T13:23:45Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"On 30 January 2010 12:31, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n> Am 30.01.2010 01:46, schrieb Jonathan del Strother:\n>> On 29 January 2010 17:44, Junio C Hamano <gitster@pobox.com> wrote:\n>>> Jonathan del Strother <maillist@steelskies.com> writes:\n>>>\n>>>> Heya,\n>>>>\n>>>> git-stash in v1.7.0-rc0 gives me several hundred lines of :\n>>>> The previous build I was using -\n>>>> 5b15950ac414a8a2d4f5eb480712abcc9fe176d2 from Jan 19th - didn't show\n>>>> this problem.  Want me to try and bisect further?\n>>>\n>>> Yes, please.\n>>>\n>>\n>> ee6fc514f2df821c2719cc49499a56ef2fb136b0 (Show submodules as modified\n>> when they contain a dirty work tree) seems to be the first bad commit.\n>\n> Thanks for pinning that down.\n>\n> I assume you have one or more submodules, maybe even with untracked\n> or yet uncommitted modified files in your tree? If so, what does git\n> status say in the superproject and in the submodule(s)?\n>\n\nYep, I have 10 submodules.  However, they're all completely clean with\nno tracked or untracked changes shown in git status.  Anything else I\ncan investigate?\n"},{"id":"133114","messageId":"4B643DEF.8010809@web.de","threadId":"22439","inReplyTo":"57518fd11001300523xf7d931by254581c8494171af@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jens Lehmann","fromEmail":"jens.lehmann@web.de","sentAt":"2010-01-30T14:10:55Z","receivedAt":"2010-01-30T14:10:55Z","isPatch":false,"sender":{"key":"jens.lehmann@web.de","avatar":"https://avatars.githubusercontent.com/u/135220?v=4"},"body":"Am 30.01.2010 14:23, schrieb Jonathan del Strother:\n> On 30 January 2010 12:31, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n>> I assume you have one or more submodules, maybe even with untracked\n>> or yet uncommitted modified files in your tree? If so, what does git\n>> status say in the superproject and in the submodule(s)?\n> \n> Yep, I have 10 submodules.  However, they're all completely clean with\n> no tracked or untracked changes shown in git status.  Anything else I\n> can investigate?\n\nThe change in behavior my patch introduced is that \"git status\" is\ncalled inside each submodule. So i would expect getting the same\nerrors when using this command:\n   git submodule foreach git status -s\n\nIt should just show\n   Entering '<submodule 1>'\n   Entering '<submodule 2>'\n   Entering '<submodule 3>'\n   Entering '<submodule 4>'\n   Entering '<submodule 5>'\n   Entering '<submodule 6>'\n   Entering '<submodule 7>'\n   Entering '<submodule 8>'\n   Entering '<submodule 9>'\n   Entering '<submodule 10>'\nwhen the submodules are not dirty. What do you get?\n\n\nThe error message \"error: unable to find <sha1>\" is only generated in\nsha1_loose_object_info() when map_sha1_file() fails. Its single caller\nbeing sha1_object_info(), which is called by many git commands. Does\nthat ring a bell for somebody?\n"},{"id":"133119","messageId":"57518fd11001300836v7f21a8a9qc09953d9091a4513@mail.gmail.com","threadId":"22439","inReplyTo":"4B643DEF.8010809@web.de","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-30T16:36:45Z","receivedAt":"2010-01-30T16:36:45Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"On 30 January 2010 14:10, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n> Am 30.01.2010 14:23, schrieb Jonathan del Strother:\n>> On 30 January 2010 12:31, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n>>> I assume you have one or more submodules, maybe even with untracked\n>>> or yet uncommitted modified files in your tree? If so, what does git\n>>> status say in the superproject and in the submodule(s)?\n>>\n>> Yep, I have 10 submodules.  However, they're all completely clean with\n>> no tracked or untracked changes shown in git status.  Anything else I\n>> can investigate?\n>\n> The change in behavior my patch introduced is that \"git status\" is\n> called inside each submodule. So i would expect getting the same\n> errors when using this command:\n>   git submodule foreach git status -s\n>\n> It should just show\n>   Entering '<submodule 1>'\n>   Entering '<submodule 2>'\n>   Entering '<submodule 3>'\n>   Entering '<submodule 4>'\n>   Entering '<submodule 5>'\n>   Entering '<submodule 6>'\n>   Entering '<submodule 7>'\n>   Entering '<submodule 8>'\n>   Entering '<submodule 9>'\n>   Entering '<submodule 10>'\n> when the submodules are not dirty. What do you get?\n>\n\nCorrect - I just get that output.\n"},{"id":"133137","messageId":"7v8wbfnyz9.fsf@alter.siamese.dyndns.org","threadId":"22439","inReplyTo":"57518fd11001300836v7f21a8a9qc09953d9091a4513@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T20:01:46Z","receivedAt":"2010-01-30T20:01:46Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Please try this.\n\nThe thing is that \"add -u\" internally runs \"diff-files\" equivalent, but\nthe code to check the submodule freshness doesn't reset the GIT_INDEX_FILE\nexported from the caller and tries to use that even when checking the\nsubmodule repository.\n\ndiff --git a/submodule.c b/submodule.c\nindex ca0527f..8bd0a30 100644\n--- a/submodule.c\n+++ b/submodule.c\n@@ -126,7 +126,7 @@ int is_submodule_modified(const char *path)\n \t\t\"--porcelain\",\n \t\tNULL,\n \t};\n-\tchar *env[3];\n+\tchar *env[4];\n \tstruct strbuf buf = STRBUF_INIT;\n \n \tstrbuf_addf(&buf, \"%s/.git/\", path);\n@@ -142,7 +142,9 @@ int is_submodule_modified(const char *path)\n \tenv[0] = strbuf_detach(&buf, NULL);\n \tstrbuf_addf(&buf, \"GIT_DIR=%s/.git\", path);\n \tenv[1] = strbuf_detach(&buf, NULL);\n-\tenv[2] = NULL;\n+\tstrbuf_addf(&buf, \"GIT_INDEX_FILE=\");\n+\tenv[2] = strbuf_detach(&buf, NULL);\n+\tenv[3] = NULL;\n \n \tmemset(&cp, 0, sizeof(cp));\n \tcp.argv = argv;\n@@ -161,6 +163,7 @@ int is_submodule_modified(const char *path)\n \n \tfree(env[0]);\n \tfree(env[1]);\n+\tfree(env[2]);\n \tstrbuf_release(&buf);\n \treturn len != 0;\n }\n"},{"id":"133138","messageId":"7vvdejmjaj.fsf@alter.siamese.dyndns.org","threadId":"22439","inReplyTo":"7v8wbfnyz9.fsf@alter.siamese.dyndns.org","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T20:25:56Z","receivedAt":"2010-01-30T20:25:56Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Junio C Hamano <gitster@pobox.com> writes:\n\n> Please try this.\n\noops, but with this, too.\n\n> diff --git a/submodule.c b/submodule.c\n> index ca0527f..8bd0a30 100644\n> --- a/submodule.c\n> +++ b/submodule.c\n> ...\n> @@ -142,7 +142,9 @@ int is_submodule_modified(const char *path)\n>  \tenv[0] = strbuf_detach(&buf, NULL);\n>  \tstrbuf_addf(&buf, \"GIT_DIR=%s/.git\", path);\n>  \tenv[1] = strbuf_detach(&buf, NULL);\n> -\tenv[2] = NULL;\n> +\tstrbuf_addf(&buf, \"GIT_INDEX_FILE=\");\n\nThis should be:\n\n\tstrbuf_addf(&buf, \"GIT_INDEX_FILE\");\n\n> +\tenv[2] = strbuf_detach(&buf, NULL);\n> +\tenv[3] = NULL;\n>  \n>  \tmemset(&cp, 0, sizeof(cp));\n>  \tcp.argv = argv;\n"},{"id":"133139","messageId":"7viqajmj2w.fsf_-_@alter.siamese.dyndns.org","threadId":"22439","inReplyTo":"7vvdejmjaj.fsf@alter.siamese.dyndns.org","subject":"[PATCH] is_submodule_modified(): fix breakage with external GIT_INDEX_FILE","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-30T20:30:31Z","receivedAt":"2010-01-30T20:30:31Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Even when the environment was given for the top-level process, checking\nin the submodule work tree should use the index file associated with the\nwork tree of the submodule.  Do not export it to the environment.\n\nSigned-off-by: Junio C Hamano <gitster@pobox.com>\n---\n\n * This seems to pass all the tests, so I'm inclined to push it out as\n   a part of 1.7.0-rc1.  There might be some other enviroment variables\n   we shouldn't be leaking out to the submodule environment, but that can\n   be spotted and fixed in later patches before the final.\n\n submodule.c |    7 +++++--\n 1 files changed, 5 insertions(+), 2 deletions(-)\n\ndiff --git a/submodule.c b/submodule.c\nindex ca0527f..6f7c210 100644\n--- a/submodule.c\n+++ b/submodule.c\n@@ -126,7 +126,7 @@ int is_submodule_modified(const char *path)\n \t\t\"--porcelain\",\n \t\tNULL,\n \t};\n-\tchar *env[3];\n+\tchar *env[4];\n \tstruct strbuf buf = STRBUF_INIT;\n \n \tstrbuf_addf(&buf, \"%s/.git/\", path);\n@@ -142,7 +142,9 @@ int is_submodule_modified(const char *path)\n \tenv[0] = strbuf_detach(&buf, NULL);\n \tstrbuf_addf(&buf, \"GIT_DIR=%s/.git\", path);\n \tenv[1] = strbuf_detach(&buf, NULL);\n-\tenv[2] = NULL;\n+\tstrbuf_addf(&buf, \"GIT_INDEX_FILE\");\n+\tenv[2] = strbuf_detach(&buf, NULL);\n+\tenv[3] = NULL;\n \n \tmemset(&cp, 0, sizeof(cp));\n \tcp.argv = argv;\n@@ -161,6 +163,7 @@ int is_submodule_modified(const char *path)\n \n \tfree(env[0]);\n \tfree(env[1]);\n+\tfree(env[2]);\n \tstrbuf_release(&buf);\n \treturn len != 0;\n }\n-- \n1.7.0.rc1.141.gbc8ce\n"},{"id":"133140","messageId":"4B649A18.3050907@web.de","threadId":"22439","inReplyTo":"57518fd11001300836v7f21a8a9qc09953d9091a4513@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jens Lehmann","fromEmail":"jens.lehmann@web.de","sentAt":"2010-01-30T20:44:08Z","receivedAt":"2010-01-30T20:44:08Z","isPatch":false,"sender":{"key":"jens.lehmann@web.de","avatar":"https://avatars.githubusercontent.com/u/135220?v=4"},"body":"Am 30.01.2010 17:36, schrieb Jonathan del Strother:\n> On 30 January 2010 14:10, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n>> Am 30.01.2010 14:23, schrieb Jonathan del Strother:\n>>> On 30 January 2010 12:31, Jens Lehmann <Jens.Lehmann@web.de> wrote:\n>>>> I assume you have one or more submodules, maybe even with untracked\n>>>> or yet uncommitted modified files in your tree? If so, what does git\n>>>> status say in the superproject and in the submodule(s)?\n>>>\n>>> Yep, I have 10 submodules.  However, they're all completely clean with\n>>> no tracked or untracked changes shown in git status.  Anything else I\n>>> can investigate?\n>>\n>> The change in behavior my patch introduced is that \"git status\" is\n>> called inside each submodule. So i would expect getting the same\n>> errors when using this command:\n>>   git submodule foreach git status -s\n>>\n>> It should just show\n>>   Entering '<submodule 1>'\n>>   Entering '<submodule 2>'\n>>   Entering '<submodule 3>'\n>>   Entering '<submodule 4>'\n>>   Entering '<submodule 5>'\n>>   Entering '<submodule 6>'\n>>   Entering '<submodule 7>'\n>>   Entering '<submodule 8>'\n>>   Entering '<submodule 9>'\n>>   Entering '<submodule 10>'\n>> when the submodules are not dirty. What do you get?\n>>\n> \n> Correct - I just get that output.\n\nHm, so nothing unusual there. I really wonder what is the problem here,\nas calling \"git status\" inside the submodules works fine when issued via\n\"git submodule foreach\", but not when done via run_command()!?\n\nSo i would like to ask some more questions:\n\n- Under what operating system and on what filesystem is this happening?\n\n- Is there anything unusual about your repo (e.g. using GIT_WORK_TREE\n  or having the object database somewhere else that in .git in the\n  superproject or any of the submodules)?\n\n- You are just issuing a \"git stash\" to stash some changes in the\n  superproject when that happens, right?\n\n- The hashes that show up as \"unable to find\" are reachable via \"git\n  show\" in the superproject, not in the submodules, right?\n\n- Do these hashes have any relation to the contents you are stashing?\n\n- The following patch should suppress (but not solve) this problem when\n  applied to a version of git that contains\n  4d34477f4c5dbebc55aa1362fd705440590a85f1 (git diff: Don't test\n  submodule dirtiness with --ignore-submodules), e.g. current next.\n  Could you please verify that?\n\n---8<---\ndiff --git a/git-stash.sh b/git-stash.sh\nindex 3a0685f..e9b47b4 100755\n--- a/git-stash.sh\n+++ b/git-stash.sh\n@@ -105,7 +105,7 @@ create_stash () {\n                w_tree=$(GIT_INDEX_FILE=\"$TMP-index\" git write-tree) ||\n                die \"Cannot save the current worktree state\"\n\n-               git diff-tree -p HEAD $w_tree > \"$TMP-patch\" &&\n+               git diff-tree --ignore-submodules -p HEAD $w_tree > \"$TMP-patch\"\n                test -s \"$TMP-patch\" ||\n                die \"No changes selected\"\n"},{"id":"133187","messageId":"57518fd11001311116t1bde882dub1dd3ca4af201b2e@mail.gmail.com","threadId":"22439","inReplyTo":"7vvdejmjaj.fsf@alter.siamese.dyndns.org","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-31T19:16:53Z","receivedAt":"2010-01-31T19:16:53Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"On 30 January 2010 20:25, Junio C Hamano <gitster@pobox.com> wrote:\n> Junio C Hamano <gitster@pobox.com> writes:\n>\n>> Please try this.\n>\n> oops, but with this, too.\n>\n>> diff --git a/submodule.c b/submodule.c\n>> index ca0527f..8bd0a30 100644\n>> --- a/submodule.c\n>> +++ b/submodule.c\n>> ...\n>> @@ -142,7 +142,9 @@ int is_submodule_modified(const char *path)\n>>       env[0] = strbuf_detach(&buf, NULL);\n>>       strbuf_addf(&buf, \"GIT_DIR=%s/.git\", path);\n>>       env[1] = strbuf_detach(&buf, NULL);\n>> -     env[2] = NULL;\n>> +     strbuf_addf(&buf, \"GIT_INDEX_FILE=\");\n>\n> This should be:\n>\n>        strbuf_addf(&buf, \"GIT_INDEX_FILE\");\n>\n>> +     env[2] = strbuf_detach(&buf, NULL);\n>> +     env[3] = NULL;\n>>\n>>       memset(&cp, 0, sizeof(cp));\n>>       cp.argv = argv;\n>\n\nSorry, I'm not sure I follow your amendment - it looks exactly like\nthe patch you originally supplied?\n\nWith that original patch applied, I no longer get the 'unable to find'\nerrors on stashing.  However, git-status shows all my submodules as\nbeing modified, but there appear to be no local changes :\n\n[jon@gir:Developer/AudioBooWeb]$ git status\n# On branch giterror\n# Changed but not updated:\n#   (use \"git add <file>...\" to update what will be committed)\n#   (use \"git checkout -- <file>...\" to discard changes in working directory)\n#\n#\tmodified:   shared/vendor/plugins/acts_as_list\n#\tmodified:   shared/vendor/plugins/cucumber\n#\tmodified:   shared/vendor/plugins/delayed_job\n#\tmodified:   shared/vendor/plugins/haml\n#\tmodified:   shared/vendor/plugins/hoptoad_notifier\n#\tmodified:   shared/vendor/plugins/machinist\n#\tmodified:   shared/vendor/plugins/newrelic_rpm\n#\tmodified:   shared/vendor/plugins/rspec\n#\tmodified:   shared/vendor/plugins/rspec-rails\n#\tmodified:   shared/vendor/rails\n#\nno changes added to commit (use \"git add\" and/or \"git commit -a\")\n\n[jon@gir:Developer/AudioBooWeb]$ git diff\ndiff --git a/shared/vendor/plugins/acts_as_list\nb/shared/vendor/plugins/acts_as_list\ndiff --git a/shared/vendor/plugins/cucumber b/shared/vendor/plugins/cucumber\ndiff --git a/shared/vendor/plugins/delayed_job\nb/shared/vendor/plugins/delayed_job\ndiff --git a/shared/vendor/plugins/haml b/shared/vendor/plugins/haml\ndiff --git a/shared/vendor/plugins/hoptoad_notifier\nb/shared/vendor/plugins/hoptoad_notifier\ndiff --git a/shared/vendor/plugins/machinist b/shared/vendor/plugins/machinist\ndiff --git a/shared/vendor/plugins/newrelic_rpm\nb/shared/vendor/plugins/newrelic_rpm\ndiff --git a/shared/vendor/plugins/rspec b/shared/vendor/plugins/rspec\ndiff --git a/shared/vendor/plugins/rspec-rails\nb/shared/vendor/plugins/rspec-rails\ndiff --git a/shared/vendor/rails b/shared/vendor/rails\n"},{"id":"133191","messageId":"57518fd11001311121wf749cf3nd2b7ae55f3ea2e61@mail.gmail.com","threadId":"22439","inReplyTo":"57518fd11001311116t1bde882dub1dd3ca4af201b2e@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Jonathan del Strother","fromEmail":"maillist@steelskies.com","sentAt":"2010-01-31T19:21:10Z","receivedAt":"2010-01-31T19:21:10Z","isPatch":false,"sender":{"key":"jon.delstrother@bestbefore.tv","avatar":"https://gravatar.com/avatar/754e21ab701c00e2d21fc261187254c34b2a1c0b959d9ee5be1a295990be3081?d=mp&s=160"},"body":"On 31 January 2010 19:16, Jonathan del Strother <maillist@steelskies.com> wrote:\n> On 30 January 2010 20:25, Junio C Hamano <gitster@pobox.com> wrote:\n>> Junio C Hamano <gitster@pobox.com> writes:\n>>\n>>> Please try this.\n>>\n>> oops, but with this, too.\n>>\n>>> diff --git a/submodule.c b/submodule.c\n>>> index ca0527f..8bd0a30 100644\n>>> --- a/submodule.c\n>>> +++ b/submodule.c\n>>> ...\n>>> @@ -142,7 +142,9 @@ int is_submodule_modified(const char *path)\n>>>       env[0] = strbuf_detach(&buf, NULL);\n>>>       strbuf_addf(&buf, \"GIT_DIR=%s/.git\", path);\n>>>       env[1] = strbuf_detach(&buf, NULL);\n>>> -     env[2] = NULL;\n>>> +     strbuf_addf(&buf, \"GIT_INDEX_FILE=\");\n>>\n>> This should be:\n>>\n>>        strbuf_addf(&buf, \"GIT_INDEX_FILE\");\n>>\n>>> +     env[2] = strbuf_detach(&buf, NULL);\n>>> +     env[3] = NULL;\n>>>\n>>>       memset(&cp, 0, sizeof(cp));\n>>>       cp.argv = argv;\n>>\n>\n> Sorry, I'm not sure I follow your amendment - it looks exactly like\n> the patch you originally supplied?\n>\n> With that original patch applied, I no longer get the 'unable to find'\n> errors on stashing.  However, git-status shows all my submodules as\n> being modified, but there appear to be no local changes :\n>\n> [jon@gir:Developer/AudioBooWeb]$ git status\n> # On branch giterror\n> # Changed but not updated:\n> #   (use \"git add <file>...\" to update what will be committed)\n> #   (use \"git checkout -- <file>...\" to discard changes in working directory)\n> #\n> #       modified:   shared/vendor/plugins/acts_as_list\n> #       modified:   shared/vendor/plugins/cucumber\n> #       modified:   shared/vendor/plugins/delayed_job\n> #       modified:   shared/vendor/plugins/haml\n> #       modified:   shared/vendor/plugins/hoptoad_notifier\n> #       modified:   shared/vendor/plugins/machinist\n> #       modified:   shared/vendor/plugins/newrelic_rpm\n> #       modified:   shared/vendor/plugins/rspec\n> #       modified:   shared/vendor/plugins/rspec-rails\n> #       modified:   shared/vendor/rails\n> #\n> no changes added to commit (use \"git add\" and/or \"git commit -a\")\n>\n> [jon@gir:Developer/AudioBooWeb]$ git diff\n> diff --git a/shared/vendor/plugins/acts_as_list\n> b/shared/vendor/plugins/acts_as_list\n> diff --git a/shared/vendor/plugins/cucumber b/shared/vendor/plugins/cucumber\n> diff --git a/shared/vendor/plugins/delayed_job\n> b/shared/vendor/plugins/delayed_job\n> diff --git a/shared/vendor/plugins/haml b/shared/vendor/plugins/haml\n> diff --git a/shared/vendor/plugins/hoptoad_notifier\n> b/shared/vendor/plugins/hoptoad_notifier\n> diff --git a/shared/vendor/plugins/machinist b/shared/vendor/plugins/machinist\n> diff --git a/shared/vendor/plugins/newrelic_rpm\n> b/shared/vendor/plugins/newrelic_rpm\n> diff --git a/shared/vendor/plugins/rspec b/shared/vendor/plugins/rspec\n> diff --git a/shared/vendor/plugins/rspec-rails\n> b/shared/vendor/plugins/rspec-rails\n> diff --git a/shared/vendor/rails b/shared/vendor/rails\n>\n\n...  however, the latest version of master\n(b0883aa6c77111e88496bd0afe073caf68ab9f99) gives me no errors, and\n(correctly) doesn't show my submodules as being modified.  I still\ndon't quite follow exactly what was wrong, but thanks :)\n"},{"id":"133190","messageId":"7vmxzudqs8.fsf@alter.siamese.dyndns.org","threadId":"22439","inReplyTo":"57518fd11001311116t1bde882dub1dd3ca4af201b2e@mail.gmail.com","subject":"Re: v1.7.0-rc0 shows lots of \"unable to find <sha1>\" on git-stash","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2010-01-31T19:21:11Z","receivedAt":"2010-01-31T19:21:11Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Jonathan del Strother <maillist@steelskies.com> writes:\n\n>>> +     strbuf_addf(&buf, \"GIT_INDEX_FILE=\");\n>>\n>> This should be:\n>>\n>>        strbuf_addf(&buf, \"GIT_INDEX_FILE\");\n>\n> Sorry, I'm not sure I follow your amendment - it looks exactly like\n> the patch you originally supplied?\n\nLack of the last \"=\" tells: \"Instead of exporting GIT_INDEX_FILE with an\nempty string as its value, unexport it.\"\n"}]}