summaryrefslogtreecommitdiff
path: root/src/ipcpd
diff options
context:
space:
mode:
authorDimitri Staessens <dimitri@ouroboros.rocks>2026-05-25 14:50:30 +0200
committerSander Vrijders <sander@ouroboros.rocks>2026-05-27 15:55:08 +0200
commita5ab03c956dce6df3148bb2df0cf8f5cf759f28a (patch)
tree98604711e8d90dcdbf2c5b88e3a9bdfa5033bddf /src/ipcpd
parent8ee68491daad630f5cd9168852f974633ce5ffd4 (diff)
downloadouroboros-a5ab03c956dce6df3148bb2df0cf8f5cf759f28a.tar.gz
ouroboros-a5ab03c956dce6df3148bb2df0cf8f5cf759f28a.zip
ipcpd: Fix eth double-release in MGMT rx path
The MGMT-frame branch in eth_ipcp_packet_reader releases the spb at the top of the loop iteration; two error exits released a second time. Signed-off-by: Dimitri Staessens <dimitri@ouroboros.rocks> Signed-off-by: Sander Vrijders <sander@ouroboros.rocks>
Diffstat (limited to 'src/ipcpd')
-rw-r--r--src/ipcpd/eth/eth.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/ipcpd/eth/eth.c b/src/ipcpd/eth/eth.c
index 103ba881..d6f476f2 100644
--- a/src/ipcpd/eth/eth.c
+++ b/src/ipcpd/eth/eth.c
@@ -1298,13 +1298,13 @@ static void * eth_ipcp_packet_reader(void * o)
if (length > MGMT_FRAME_SIZE) {
log_warn("Management frame size %u exceeds %u.",
length, MGMT_FRAME_SIZE);
- goto fail_frame;
+ continue;
}
frame = malloc(sizeof(*frame));
if (frame == NULL) {
log_err("Failed to allocate frame.");
- goto fail_frame;
+ continue;
}
memcpy(frame->buf, &e_frame->payload, length);