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

old but persistent problem: bad line length character

From
PKPeter Kleiweg <p.c.j.kleiweg@rug.nl>
Date
Jun 7, 2011, 16:33 UTC
Message-ID
<alpine.DEB.1.10.1106071832470.4175@localhost>
I get this error message with git version 1.7.5.GIT: 
    fatal: protocol error: bad line length character:
Git version 1.4.4.4 works fine.

I have read this was a very old problem, and there were some fixes, then how come I still get this in the latest version of Git? All the explanations I could find about this bug don't seem to apply for my case.

How do bugs in Git get solved? I can't find an issue tracker. 
Details:

$ export GIT_TRACE=1 $ export GIT_TRACE_PACKET=1 $ git push trace: built-in: git 'push' trace: run_command: 'ssh' 'github' 'git-receive-pack '\''pebbe/Gabmap.git'\''' fatal: protocol error: bad line length character:

The output above comes immediately. When I run the ssh command listed above, it takes time before I get a response. So even if Git does run the command, it doesn't wait for a response from the server.

Setting GIT_TRACE_PACKET doesn't seem to have any effect. 

I added some debug code in pkt-line.c, function packet_read_line(). This tells me that 'buffer' that is passed to packet_read_line() contains nothing but null characters, while 'size' is set to 1000.

Running the ssh command as listed by trace works fine:

$ ssh github git-receive-pack 'pebbe/Gabmap.git' 00720444852406fd34c3eb0c8cdcb05cd2af979d2b34 refs/heads/master report-status delete-refs side-band-64k ofs-delta 0000

-- 
Peter Kleiweg
http://pkleiweg.home.xs4all.nl/
Next: Jeff King
Message 1 of 6 in “old but persistent problem: bad line length character”
  1. Peter KleiwegJun 7, 2011
  2. Jeff KingJun 7, 2011
  3. Peter KleiwegJun 7, 2011
  4. Junio C HamanoJun 8, 2011
  5. Jakub NarebskiJun 8, 2011
  6. Peter KleiwegJun 8, 2011

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.