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

Re: [PATCH] prune: keep files created after process start

From
Andreas Schwab <schwab@linux-m68k.org>
Date
Jun 19, 2016, 07:11 UTC
Message-ID
<m2wpllhcut.fsf@linux-m68k.org>
In-Reply-To
<20160619031338.GA5161@dcvr.yhbt.net>
Eric Wong <e@80x24.org> writes:
Show 6 quoted lines
> @@ -21,7 +22,7 @@ static int prune_tmp_file(const char *fullpath)
>  	struct stat st;
>  	if (lstat(fullpath, &st))
>  		return error("Could not stat '%s'", fullpath);
> -	if (st.st_mtime > expire)
> +	if (st.st_mtime > expire || st.st_ctime >= start)

That will also mean objects created (or their inode changed) up to a second before the start of prune will not be removed. For example, objects ejected out of a pack by a previous repack may be affected.

Andreas.
-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."
Previous: Jeff KingNext: Eric Wong
Message 5 of 6 in “prune: keep files created after process start”
  1. prune: keep files created after process startEric Wong, Jun 19, 2016
  2. Junio C HamanoJun 19, 2016
  3. Eric WongJun 19, 2016
  4. Jeff KingJun 19, 2016
  5. Andreas SchwabJun 19, 2016
  6. Eric WongJun 19, 2016

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.