summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/nl.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/nl.c b/lib/nl.c
index 17bd834..161cfa5 100644
--- a/lib/nl.c
+++ b/lib/nl.c
@@ -464,7 +464,7 @@ int nl_recv(struct nl_sock *sk, struct sockaddr_nl *nla,
struct ucred* tmpcreds = NULL;
int retval = 0;
- if (!buf)
+ if (!buf || !nla)
return -NLE_INVAL;
if (sk->s_flags & NL_MSG_PEEK)