Merge pull request #373 from fobser/void-arithmetic

Warning: arithmetic on a pointer to void is a GNU extension.
This commit is contained in:
Wouter Wijngaards 2020-12-11 14:07:30 +01:00 committed by GitHub
commit 48c038391a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1935,7 +1935,7 @@ comm_point_tcp_handle_write(int fd, struct comm_point* c)
log_assert(c->tcp_write_and_read || sldns_buffer_remaining(buffer) > 0);
log_assert(!c->tcp_write_and_read || c->tcp_write_byte_count < c->tcp_write_pkt_len + 2);
if(c->tcp_write_and_read) {
r = send(fd, (void*)c->tcp_write_pkt + c->tcp_write_byte_count - 2,
r = send(fd, (void*)(c->tcp_write_pkt + c->tcp_write_byte_count - 2),
c->tcp_write_pkt_len + 2 - c->tcp_write_byte_count, 0);
} else {
r = send(fd, (void*)sldns_buffer_current(buffer),