From 8f2ce4d791ebdbfcb3699f8890568964c5572a70 Mon Sep 17 00:00:00 2001 From: =?utf8?q?=D0=9A=D0=BE=D1=80=D0=B5=D0=BD=D0=B1=D0=B5=D1=80=D0=B3=20?= =?utf8?q?=D0=9C=D0=B0=D1=80=D0=BA?= Date: Thu, 30 Aug 2012 18:40:11 +0600 Subject: [PATCH] More clean NL_AUTO_PORT and NL_AUTO_SEQ usage in nl_complete_msg --- lib/nl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/nl.c b/lib/nl.c index d3e67aa..ea3e087 100644 --- a/lib/nl.c +++ b/lib/nl.c @@ -274,10 +274,10 @@ void nl_complete_msg(struct nl_sock *sk, struct nl_msg *msg) struct nlmsghdr *nlh; nlh = nlmsg_hdr(msg); - if (nlh->nlmsg_pid == 0) + if (nlh->nlmsg_pid == NL_AUTO_PORT) nlh->nlmsg_pid = sk->s_local.nl_pid; - if (nlh->nlmsg_seq == 0) + if (nlh->nlmsg_seq == NL_AUTO_SEQ) nlh->nlmsg_seq = sk->s_seq_next++; if (msg->nm_protocol == -1) -- 2.40.0