mirror of
https://github.com/git/git.git
synced 2024-11-01 23:07:55 +01:00
34df8abaf3
This removes the last parameter of recv_sideband, by which the callers told which channel bands #2 and #3 should be written to. Sayeth Shawn Pearce: The definition of the streams in the current sideband protocol are rather well defined for the one protocol that uses it, fetch-pack/receive-pack: stream #1: pack data stream #2: stderr messages, progress, meant for tty stream #3: abort message, remote is dead, goodbye! Since both callers of the function passed 2 for the parameter, we hereby remove it and send bands #2 and #3 to stderr explicitly using fprintf. This has the nice side-effect that these two streams pass through our ANSI emulation layer on Windows. Signed-off-by: Johannes Sixt <j6t@kdbg.org> Acked-by: Nicolas Pitre <nico@cam.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
13 lines
326 B
C
13 lines
326 B
C
#ifndef SIDEBAND_H
|
|
#define SIDEBAND_H
|
|
|
|
#define SIDEBAND_PROTOCOL_ERROR -2
|
|
#define SIDEBAND_REMOTE_ERROR -1
|
|
|
|
#define DEFAULT_PACKET_MAX 1000
|
|
#define LARGE_PACKET_MAX 65520
|
|
|
|
int recv_sideband(const char *me, int in_stream, int out);
|
|
ssize_t send_sideband(int fd, int band, const char *data, ssize_t sz, int packet_max);
|
|
|
|
#endif
|