systemd/coccinelle/htonl.cocci
Lennart Poettering 8e38570ebe tree-wide: htonl() is weird, let's use htobe32() instead (#3538)
Super-important change, yeah!
2016-06-15 01:26:01 +02:00

21 lines
176 B
Plaintext

@@
expression s;
@@
- htonl(s)
+ htobe32(s)
@@
expression s;
@@
- htons(s)
+ htobe16(s)
@@
expression s;
@@
- ntohl(s)
+ be32toh(s)
@@
expression s;
@@
- ntohs(s)
+ be16toh(s)