diff options
author | Junio C Hamano <gitster@pobox.com> | 2022-08-29 23:55:11 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2022-08-29 23:55:11 +0200 |
commit | 64cb4c34d1c27969c6556cbe339a73e88758d7e6 (patch) | |
tree | 142c52890f656275749c8cb771df7400653d488b /pkt-line.h | |
parent | Merge branch 'ds/decorate-filter-tweak' (diff) | |
parent | tests: use the new C rot13-filter helper to avoid PERL prereq (diff) | |
download | git-64cb4c34d1c27969c6556cbe339a73e88758d7e6.tar.xz git-64cb4c34d1c27969c6556cbe339a73e88758d7e6.zip |
Merge branch 'mt/rot13-in-c'
Test portability improvements.
* mt/rot13-in-c:
tests: use the new C rot13-filter helper to avoid PERL prereq
t0021: implementation the rot13-filter.pl script in C
t0021: avoid grepping for a Perl-specific string at filter output
Diffstat (limited to 'pkt-line.h')
-rw-r--r-- | pkt-line.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/pkt-line.h b/pkt-line.h index 1f623de60a..79c538b99e 100644 --- a/pkt-line.h +++ b/pkt-line.h @@ -32,7 +32,13 @@ void packet_buf_write(struct strbuf *buf, const char *fmt, ...) __attribute__((f int packet_flush_gently(int fd); int packet_write_fmt_gently(int fd, const char *fmt, ...) __attribute__((format (printf, 2, 3))); int write_packetized_from_fd_no_flush(int fd_in, int fd_out); -int write_packetized_from_buf_no_flush(const char *src_in, size_t len, int fd_out); +int write_packetized_from_buf_no_flush_count(const char *src_in, size_t len, + int fd_out, int *packet_counter); +static inline int write_packetized_from_buf_no_flush(const char *src_in, + size_t len, int fd_out) +{ + return write_packetized_from_buf_no_flush_count(src_in, len, fd_out, NULL); +} /* * Stdio versions of packet_write functions. When mixing these with fd |