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

Re: [PATCH] Fix handle leak in builtin-pack-objects

From
Alex Riesen <raa.lkml@gmail.com>
Date
Nov 19, 2008, 13:30 UTC
Message-ID
<81b0412b0811190530m79a11b9dx3771b9679e53e9e@mail.gmail.com>
In-Reply-To
<alpine.LFD.2.00.0811190740570.27509@xanadu.home>
2008/11/19 Nicolas Pitre <nico@cam.org>:
Show 12 quoted lines
> On Wed, 19 Nov 2008, Alex Riesen wrote:
>
>> The opened packs seem to stay open forever.
>>
>> Signed-off-by: Alex Riesen <raa.lkml@gmail.com>
>> ---
>>
>> I'm very unsure about the solution, though: it is really horrible code
>> to debug...
>
> What is the actual problem?  Pack windows are left open on purpose.
>
* expecting success: do_repack &&
     git prune-packed -v &&
     git verify-pack ${pack}.pack &&
     git cat-file blob $blob_1 > /dev/null &&
     git cat-file blob $blob_2 > /dev/null &&
     git cat-file blob $blob_3 > /dev/null
Counting objects: 3, done.
error: unknown object type 0 at offset 2032 in
.git/objects/pack/pack-8d1e04fc992cfbdb3ab72cf7abbf08cce8b1900.pack
Compressing objects: 100% (2/2), done.
fatal: unable to rename temporary pack file
.git/objects/pack/tmp_pack_s9Gijm->.git/objects/pack/pack-b8d1e04fc992cfbdbab72cf7abbf08cce8b1900.pack:
Permission denied
* FAIL 10: ... and then a repack "clears" the corruption
        do_repack &&
             git prune-packed -v &&
             git verify-pack ${pack}.pack &&
             git cat-file blob $blob_1 > /dev/null &&
             git cat-file blob $blob_2 > /dev/null &&
             git cat-file blob $blob_3 > /dev/null
Previous: Nicolas Pitre
Message 23 of 23 in “Fix handle leak in builtin-pack-objects”
  1. Fix handle leak in builtin-pack-objectsAlex Riesen, Nov 19, 2008
  2. Johannes SixtNov 19, 2008
  3. Alex RiesenNov 19, 2008
  4. Johannes SixtNov 19, 2008
  5. Nicolas PitreNov 19, 2008
  6. Johannes SixtNov 19, 2008
  7. Nicolas PitreNov 19, 2008
  8. Alex RiesenNov 19, 2008
  9. Johannes SixtNov 19, 2008
  10. Alex RiesenNov 19, 2008
  11. Nicolas PitreNov 19, 2008
  12. Johannes SixtNov 19, 2008
  13. compat/mingw.c: Teach mingw_rename() to replace read-only filesJohannes Sixt, Nov 19, 2008
  14. Alex RiesenNov 26, 2008
  15. Nicolas PitreNov 26, 2008
  16. Alex RiesenNov 26, 2008
  17. make sure packs to be replaced are closed beforehandNicolas Pitre, Dec 9, 2008
  18. Alex RiesenDec 9, 2008
  19. Johannes SixtDec 10, 2008
  20. Junio C HamanoDec 10, 2008
  21. Alex RiesenDec 10, 2008
  22. Nicolas PitreNov 19, 2008
  23. Alex RiesenNov 19, 2008

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.