projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
15411c0
)
sd-rtnl: never set serial to 0
author
Tom Gundersen
<teg@jklm.no>
Fri, 13 Mar 2015 14:49:07 +0000
(15:49 +0100)
committer
Tom Gundersen
<teg@jklm.no>
Fri, 13 Mar 2015 14:56:08 +0000
(15:56 +0100)
In the unlikely event that we wrap the counter, skip 0 as this is used
for broadcasts.
Suggested by Richard Maw.
src/libsystemd/sd-rtnl/sd-rtnl.c
patch
|
blob
|
history
diff --git
a/src/libsystemd/sd-rtnl/sd-rtnl.c
b/src/libsystemd/sd-rtnl/sd-rtnl.c
index
268d366
..
f483af9
100644
(file)
--- 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);