diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-04-02 14:43:14 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-04-02 14:43:14 -0700 |
commit | 861794b60d3a61822daf59bbde39a2a2e362738d (patch) | |
tree | 70d6c593034cedb5413b5216eb01ba810314d828 /convert.c | |
parent | Merge branch 'mt/parallel-checkout-part-1' (diff) | |
parent | t0052: add simple-ipc tests and t/helper/test-simple-ipc tool (diff) | |
download | tgif-861794b60d3a61822daf59bbde39a2a2e362738d.tar.xz |
Merge branch 'jh/simple-ipc'
A simple IPC interface gets introduced to build services like
fsmonitor on top.
* jh/simple-ipc:
t0052: add simple-ipc tests and t/helper/test-simple-ipc tool
simple-ipc: add Unix domain socket implementation
unix-stream-server: create unix domain socket under lock
unix-socket: disallow chdir() when creating unix domain sockets
unix-socket: add backlog size option to unix_stream_listen()
unix-socket: eliminate static unix_stream_socket() helper function
simple-ipc: add win32 implementation
simple-ipc: design documentation for new IPC mechanism
pkt-line: add options argument to read_packetized_to_strbuf()
pkt-line: add PACKET_READ_GENTLE_ON_READ_ERROR option
pkt-line: do not issue flush packets in write_packetized_*()
pkt-line: eliminate the need for static buffer in packet_write_gently()
Diffstat (limited to 'convert.c')
-rw-r--r-- | convert.c | 11 |
1 files changed, 8 insertions, 3 deletions
@@ -873,9 +873,13 @@ static int apply_multi_file_filter(const char *path, const char *src, size_t len goto done; if (fd >= 0) - err = write_packetized_from_fd(fd, process->in); + err = write_packetized_from_fd_no_flush(fd, process->in); else - err = write_packetized_from_buf(src, len, process->in); + err = write_packetized_from_buf_no_flush(src, len, process->in); + if (err) + goto done; + + err = packet_flush_gently(process->in); if (err) goto done; @@ -892,7 +896,8 @@ static int apply_multi_file_filter(const char *path, const char *src, size_t len if (err) goto done; - err = read_packetized_to_strbuf(process->out, &nbuf) < 0; + err = read_packetized_to_strbuf(process->out, &nbuf, + PACKET_READ_GENTLE_ON_EOF) < 0; if (err) goto done; |