git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: I'm missing isofs.h

From
Petr Baudis <pasky@ucw.cz>
Date
Apr 27, 2005, 23:51 UTC
Message-ID
<20050427235115.GN22956@pasky.ji.cz>
In-Reply-To
<20050426214338.32e9ac27.akpm@osdl.org>

Dear diary, on Wed, Apr 27, 2005 at 06:43:38AM CEST, I got a letter where Andrew Morton <akpm@osdl.org> told me that...

Show 19 quoted lines
> In a current tree, using git-pasky-0.7:
> 
> bix:/usr/src/git26> cat .git/tags/v2.6.12-rc3 
> a2755a80f40e5794ddc20e00f781af9d6320fafb
> bix:/usr/src/git26> git diff -r v2.6.12-rc3|grep isofs.h
> +#include "isofs.h"
>  #include "zisofs.h"
> +#include "isofs.h"
> +#include "isofs.h"
> +#include "isofs.h"
>  #include "zisofs.h"
> +#include "isofs.h"
> +#include "isofs.h"
> +#include "isofs.h"
> +#include "isofs.h"
> 
> 
> That diff should have included the addition of the new isofs.h, but it
> isn't there.
Ouch.

Well, using -r v2.6.12-rc3: is a workable workaround, but this is a problem. With the trailing :, you are diffing against your latest commit, whilst without the trailing :, you are diffing against your working tree. ;-)

The problem is in how the latter is implemented:
        export GIT_INDEX_FILE=$(mktemp -t gitdiff.XXXXXX)
        cp .git/index $GIT_INDEX_FILE
        read-tree -m $(tree-id "$id1")
        update-cache --refresh
        tree=$(tree-id "$id1")
	diff-cache -r -z $tree | xargs -0 cg-Xdiffdo ...

So, we are recording our adds to the index cache, but here we use a different one with the adds are not recorded - so diff-cache won't catch them.

So I fixed this by doing diff-cache --cached and updating the tmp index by the +- entries. Pushed out, thanks.

-- 
				Petr "Pasky" Baudis
Stuff: http://pasky.or.cz/
C++: an octopus made by nailing extra legs onto a dog. -- Steve Taylor
Previous: Steven ColeNext: Linus Torvalds
Message 8 of 23 in “I'm missing isofs.h”
  1. Andrew MortonApr 27, 2005
  2. Jan HarkesApr 27, 2005
  3. Petr BaudisApr 27, 2005
  4. Jan HarkesApr 27, 2005
  5. Jan HarkesApr 27, 2005
  6. Steven ColeApr 27, 2005
  7. Steven ColeApr 27, 2005
  8. Petr BaudisApr 27, 2005
  9. Linus TorvaldsApr 28, 2005
  10. Petr BaudisApr 28, 2005
  11. Junio C HamanoApr 28, 2005
  12. Junio C HamanoApr 28, 2005
  13. Make diff-cache and friends output more cg-patch friendly.Junio C Hamano, Apr 28, 2005
  14. Petr BaudisApr 28, 2005
  15. David A. WheelerApr 28, 2005
  16. Linus TorvaldsApr 28, 2005
  17. Junio C HamanoApr 28, 2005
  18. Linus TorvaldsApr 28, 2005
  19. Cogito nit: cg-update should default to "origin".David A. Wheeler, Apr 28, 2005
  20. Petr BaudisApr 28, 2005
  21. Dan HolmsandApr 28, 2005
  22. David A. WheelerApr 28, 2005
  23. Dan HolmsandApr 28, 2005

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.