Merge pull request #5760 from ton31337/fix/shorthand_operator

zebra: Use shorthand operator in ifm_read()
This commit is contained in:
Renato Westphal 2020-02-05 01:45:55 -03:00 committed by GitHub
commit 8f6ebcbeb2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 13 additions and 1 deletions

View File

@ -0,0 +1,12 @@
@@
identifier data;
constant x;
@@
(
- data = data + x
+ data += x
|
- data = data - x
+ data -= x
)

View File

@ -556,7 +556,7 @@ int ifm_read(struct if_msghdr *ifm)
* is 12 bytes larger than the 32 bit version.
*/
if (((struct sockaddr *)cp)->sa_family == AF_UNSPEC)
cp = cp + 12;
cp += 12;
#endif
/* Look up for RTA_IFP and skip others. */