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

Re: Looking for help to understand external filter driver code

From
Torsten Bögershausen <tboegi@web.de>
Date
Jul 20, 2016, 02:33 UTC
Message-ID
<cdb8005a-2ed9-04da-fdbf-600accfac38f@web.de>
In-Reply-To
<BDD74384-AA02-4B60-A246-504B4C6DDF02@gmail.com>
On 07/20/2016 12:01 AM, Lars Schneider wrote:
Show 13 quoted lines
>
> On 19 Jul 2016, at 23:33, Junio C Hamano <gitster@pobox.com> wrote:
>
>> Lars Schneider <larsxschneider@gmail.com> writes:
>>
>>> Git writes --> 4 byte filename length
>>> Git writes --> filename string
>>
>> Why limit to 32GB?  Perhaps NUL termination is more appropriate
>> here?
> OK, I will use NUL termination for the filename.
> You're also right about the limit - I will use 8 byte to encode the
> content length.

Is there any reason to encode the file length in binary format? With all the discussions about big endianess, little endianess, 4GiB or 32 GiB. How about simply writing the length as ASCII ?

Unless we don't want to have a "spare" field for future extensions, it could be good to add an option field, which may be empty. On top of that, do we want a field separator different from the line separator ?

How about this: <options><TAB><length><TAB><filename><NUL>

<options> may be "var=value;var2=value2" or simply ""
Previous: Lars SchneiderNext: Jakub Narębski
Message 7 of 10 in “Looking for help to understand external filter driver code”
  1. Lars SchneiderJul 19, 2016
  2. Junio C HamanoJul 19, 2016
  3. Junio C HamanoJul 19, 2016
  4. Lars SchneiderJul 19, 2016
  5. Junio C HamanoJul 19, 2016
  6. Lars SchneiderJul 19, 2016
  7. Torsten BögershausenJul 20, 2016
  8. Jakub NarębskiJul 20, 2016
  9. Lars SchneiderJul 20, 2016
  10. Jeff KingJul 20, 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.