1
1
mirror of https://github.com/systemd/systemd-stable.git synced 2024-12-23 17:34:00 +03:00
systemd-stable/coccinelle/xsprintf.cocci
Frantisek Sumsal cb60571b31 coccinelle: skip the xsprintf transformation on man pages
since we don't expose xsprintf to users.
2020-10-04 12:32:21 +02:00

8 lines
185 B
Plaintext

@@
position p : script:python() { not p[0].file.startswith("man/") };
expression e, fmt;
expression list vaargs;
@@
- snprintf@p(e, sizeof(e), fmt, vaargs);
+ xsprintf(e, fmt, vaargs);