From: Felix Fietkau Date: Mon, 6 Jul 2015 16:42:36 +0000 (+0200) Subject: ubusd: fix offset calculation (based on patch by Yang Chao) X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=ab1bffddb3574d18d36f321dce81e7e170abb3d6;p=oweals%2Fubus.git ubusd: fix offset calculation (based on patch by Yang Chao) Signed-off-by: Felix Fietkau --- diff --git a/ubusd.c b/ubusd.c index 65b82ca..aa72351 100644 --- a/ubusd.c +++ b/ubusd.c @@ -242,7 +242,7 @@ retry: fd_buf.fd = -1; - iov.iov_base = &cl->hdrbuf + offset; + iov.iov_base = ((char *) &cl->hdrbuf) + offset; iov.iov_len = sizeof(cl->hdrbuf) - offset; if (cl->pending_msg_fd < 0) {