diff options
author | Tom Gundersen <teg@jklm.no> | 2015-03-13 15:49:07 +0100 |
---|---|---|
committer | Tom Gundersen <teg@jklm.no> | 2015-03-13 15:56:08 +0100 |
commit | 913b0eef1a01e0c78f0453b0174e75d5caae1023 (patch) | |
tree | e9ef4a18800dc85ebbef61ad8d327309072f4bb1 /src | |
parent | 15411c0cb1192799b37ec8f25d6f30e8d7292fc6 (diff) |
sd-rtnl: never set serial to 0
In the unlikely event that we wrap the counter, skip 0 as this is used
for broadcasts.
Suggested by Richard Maw.
Diffstat (limited to 'src')
-rw-r--r-- | src/libsystemd/sd-rtnl/sd-rtnl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libsystemd/sd-rtnl/sd-rtnl.c b/src/libsystemd/sd-rtnl/sd-rtnl.c index 268d366050..f483af991b 100644 --- a/src/libsystemd/sd-rtnl/sd-rtnl.c +++ b/src/libsystemd/sd-rtnl/sd-rtnl.c @@ -262,7 +262,7 @@ static void rtnl_seal_message(sd_rtnl *rtnl, sd_rtnl_message *m) { assert(m); assert(m->hdr); - m->hdr->nlmsg_seq = rtnl->serial++; + m->hdr->nlmsg_seq = rtnl->serial++ ? : rtnl->serial++; rtnl_message_seal(m); |