summaryrefslogtreecommitdiffstats
path: root/isisd/isis_bpf.c
diff options
context:
space:
mode:
Diffstat (limited to 'isisd/isis_bpf.c')
-rw-r--r--isisd/isis_bpf.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/isisd/isis_bpf.c b/isisd/isis_bpf.c
index 4d5b16513..1e70cc132 100644
--- a/isisd/isis_bpf.c
+++ b/isisd/isis_bpf.c
@@ -29,6 +29,7 @@
#include <net/bpf.h>
#include "log.h"
+#include "network.h"
#include "stream.h"
#include "if.h"
@@ -338,8 +339,14 @@ isis_send_pdu_bcast (struct isis_circuit *circuit, int level)
/* now we can send this */
written = write (circuit->fd, sock_buff, buflen);
-
- return ISIS_OK;
+ if (written < 0)
+ {
+ zlog_warn("IS-IS bpf: could not transmit packet on %s: %s",
+ circuit->interface->name, safe_strerror(errno));
+ if (ERRNO_IO_RETRY(errno))
+ return ISIS_WARNING;
+ return ISIS_ERROR;
+ }
}
int