diff options
| author | Dirk Engling <erdgeist@erdgeist.org> | 2026-10-18 03:44:30 +0200 |
|---|---|---|
| committer | Dirk Engling <erdgeist@erdgeist.org> | 2026-10-18 03:44:30 +0200 |
| commit | ded5a43ed37fe7a19e79c33bd1b6146ff41c316a (patch) | |
| tree | 7cabe2bb0486d3080dbc428213842356a8795b5a | |
| parent | 4a143ded7ab67d1707241bf9028524cec3532fe4 (diff) | |
| -rw-r--r-- | ot_livesync.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ot_livesync.c b/ot_livesync.c index fbedb73..f620592 100644 --- a/ot_livesync.c +++ b/ot_livesync.c | |||
| @@ -143,9 +143,9 @@ static void livesync_handle_peersync(struct ot_workstruct *ws, size_t peer_size) | |||
| 143 | /* Now basic sanity checks have been done on the live sync packet | 143 | /* Now basic sanity checks have been done on the live sync packet |
| 144 | We might add more testing and logging. */ | 144 | We might add more testing and logging. */ |
| 145 | while ((ssize_t)(off + sizeof(ot_hash) + peer_size) <= ws->request_size) { | 145 | while ((ssize_t)(off + sizeof(ot_hash) + peer_size) <= ws->request_size) { |
| 146 | uint8_t *peer_ip = ws->request + off + sizeof(ot_hash); | 146 | char *peer_ip = ws->request + off + sizeof(ot_hash); |
| 147 | if (peer_size == OT_PEER_SIZE4) | 147 | if (peer_size == OT_PEER_SIZE4) |
| 148 | memcpy(&ws->peer + sizeof(V4mappedprefix), peer_ip, peer_size); | 148 | memcpy(&ws->peer[0] + sizeof(V4mappedprefix), peer_ip, peer_size); |
| 149 | else | 149 | else |
| 150 | memcpy(&ws->peer, peer_ip, peer_size); | 150 | memcpy(&ws->peer, peer_ip, peer_size); |
| 151 | ws->hash = (ot_hash *)(ws->request + off); | 151 | ws->hash = (ot_hash *)(ws->request + off); |
