diff options
Diffstat (limited to 'ospf6d/ospf6_message.c')
| -rw-r--r-- | ospf6d/ospf6_message.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/ospf6d/ospf6_message.c b/ospf6d/ospf6_message.c index c608a01102..228a525e76 100644 --- a/ospf6d/ospf6_message.c +++ b/ospf6d/ospf6_message.c @@ -26,6 +26,7 @@ #include "command.h" #include "thread.h" #include "linklist.h" +#include "lib_errors.h" #include "ospf6_proto.h" #include "ospf6_lsa.h" @@ -1503,14 +1504,6 @@ int ospf6_iobuf_size(unsigned int size) recvnew = XMALLOC(MTYPE_OSPF6_MESSAGE, size); sendnew = XMALLOC(MTYPE_OSPF6_MESSAGE, size); - if (recvnew == NULL || sendnew == NULL) { - if (recvnew) - XFREE(MTYPE_OSPF6_MESSAGE, recvnew); - if (sendnew) - XFREE(MTYPE_OSPF6_MESSAGE, sendnew); - zlog_debug("Could not allocate I/O buffer of size %d.", size); - return iobuflen; - } if (recvbuf) XFREE(MTYPE_OSPF6_MESSAGE, recvbuf); @@ -1566,7 +1559,8 @@ int ospf6_receive(struct thread *thread) /* receive message */ len = ospf6_recvmsg(&src, &dst, &ifindex, iovector); if (len > iobuflen) { - zlog_err("Excess message read"); + flog_err(LIB_ERR_DEVELOPMENT, + "Excess message read"); return 0; } @@ -1714,7 +1708,7 @@ static void ospf6_send(struct in6_addr *src, struct in6_addr *dst, /* send message */ len = ospf6_sendmsg(src, dst, &oi->interface->ifindex, iovector); if (len != ntohs(oh->length)) - zlog_err("Could not send entire message"); + flog_err(LIB_ERR_DEVELOPMENT, "Could not send entire message"); } static uint32_t ospf6_packet_max(struct ospf6_interface *oi) |
