1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-14 15:21:37 +03:00
systemd/coccinelle/errno.cocci
Lennart Poettering 94c156cd45 tree-wide: make use of log_error_errno() return value in more cases
The previous coccinelle semantic patch that improved usage of
log_error_errno()'s return value, only looked for log_error_errno()
invocations with a single parameter after the error parameter. Update
the patch to handle arbitrary numbers of additional arguments.
2015-09-09 14:58:26 +02:00

49 lines
618 B
Plaintext

@@
identifier r;
expression e;
@@
- r = -e;
- log_error_errno(e,
+ r = log_error_errno(e,
...);
@@
identifier r;
expression e;
@@
- log_error_errno(e,
+ r = log_error_errno(e,
...);
- r = -e;
@@
identifier r;
expression e;
@@
- r = log_error_errno(e,
+ return log_error_errno(e,
...);
- return r;
@@
identifier r;
expression e;
@@
- r = -e;
- log_warning_errno(e,
+ r = log_warning_errno(e,
...);
@@
identifier r;
expression e;
@@
- log_warning_errno(e,
+ r = log_warning_errno(e,
...);
- r = -e;
@@
identifier r;
expression e;
@@
- r = log_warning_errno(e,
+ return log_warning_errno(e,
...);
- return r;