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

Re: [PATCH v7 2/5] setup: sanity check file size in read_gitfile_gently

From
erik elfström <erik.elfstrom@gmail.com>
Date
Jun 14, 2015, 17:21 UTC
Message-ID
<CAMpP7NZ2tqZ5cv=9=gJqDZ5m0LOZtsHGvt-ntZcp6cBA6X5tqg@mail.gmail.com>
In-Reply-To
<CAPig+cTQKxD9WRV3spVce=SfeECo4XR_ujZ1sGecuhTL-3DeRw@mail.gmail.com>
On Sun, Jun 14, 2015 at 5:42 AM, Eric Sunshine <sunshine@sunshineco.com> wrote:
Show 6 quoted lines
>
> This variable name doesn't convey much about its purpose, and
> introduces a bit of maintenance burden if the limit is some day
> changed. Perhaps "sane_size_limit" or something even more descriptive
> (and/or terse) would be better.
>
Would you be happy with this change?
-       static const int one_MB = 1 << 20;
+       static const int max_file_size = 1 << 20;  /* 1MB */
Previous: Eric SunshineNext: Eric Sunshine
Message 5 of 9 in “Improving performance of git clean”
  1. 0/5 Improving performance of git cleanErik Elfström, Jun 9, 2015
  2. 1/5 setup: add gentle version of read_gitfileErik Elfström, Jun 9, 2015
  3. 2/5 setup: sanity check file size in read_gitfile_gentlyErik Elfström, Jun 9, 2015
  4. Eric SunshineJun 14, 2015
  5. erik elfströmJun 14, 2015
  6. Eric SunshineJun 15, 2015
  7. 3/5 t7300: add tests to document behavior of clean and nested gitErik Elfström, Jun 9, 2015
  8. 4/5 p7300: add performance tests for cleanErik Elfström, Jun 9, 2015
  9. 5/5 clean: improve performance when removing lots of directoriesErik Elfström, Jun 9, 2015

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.