diff options
Diffstat (limited to 'common/src/bfd.cpp')
| -rw-r--r-- | common/src/bfd.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/common/src/bfd.cpp b/common/src/bfd.cpp index 3bfe13c..d1112e8 100644 --- a/common/src/bfd.cpp +++ b/common/src/bfd.cpp @@ -113,12 +113,12 @@ static ssize_t bfd_vtysh_client_receive(struct bfd_vtysh_client *client, char *b uint8_t buf[CMSG_SPACE(sizeof(int))]; struct cmsghdr align; } u; - struct msghdr mh = { - .msg_iov = iov, - .msg_iovlen = 1, - .msg_control = u.buf, - .msg_controllen = sizeof(u.buf), - }; + struct msghdr mh; + memset(&mh, 0, sizeof(mh)); + mh.msg_iov = iov; + mh.msg_iovlen = 1; + mh.msg_control = u.buf; + mh.msg_controllen = sizeof(u.buf); struct cmsghdr *cmh = CMSG_FIRSTHDR(&mh); ssize_t ret; |
