surprising value of LARGE_PACKET_MAX

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I implemented a git-filter-server using the long-running process
protocol, and was surprised to discover in testing that git rejected
a maximally sized pkt-line starting with "ffff" as having an invalid
size.

The docs don't say what the maximum size is, so I assumed I could make
it as large as the length header allows, which I think is a natural
conclusion to draw from the documentation. But looking in git's source,
fff0 is the maximum:

#define LARGE_PACKET_MAX 65520
#define LARGE_PACKET_DATA_MAX (LARGE_PACKET_MAX - 4)

Which dates back to commit d47f3db75c58139cdcbca5cc63b17bf5db293b6a in
2006, which does not give a rationalle for the slightly small
size. Whatever the reason, it seems likely that changing that would be
likely to break interoperability with older versions of git.

Perhaps the best thing to do would be to document it in
Documentation/technical/protocol-common.txt

-- 
see shy jo

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux