diff options
author | Michal Schmidt <mschmidt@redhat.com> | 2015-11-05 13:44:18 +0100 |
---|---|---|
committer | Michal Schmidt <mschmidt@redhat.com> | 2015-11-09 20:01:06 +0100 |
commit | b3e3bb19a06795ee1eb3679a839f4687ba99143f (patch) | |
tree | 9648c9335994d3744bbdd5210266b05c3964d85d /coccinelle | |
parent | 351825cc7355fec1c7fc6cb46c16ba68f2aea76c (diff) | |
download | systemd-b3e3bb19a06795ee1eb3679a839f4687ba99143f.tar.gz |
coccinelle: additional errno.cocci hunk
rewrites:
log_error_errno(errno, ...);
return -errno;
into:
return log_error_errno(errno, ...);
Diffstat (limited to 'coccinelle')
-rw-r--r-- | coccinelle/errno.cocci | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/coccinelle/errno.cocci b/coccinelle/errno.cocci index 0b14d22438..ed74c0a98a 100644 --- a/coccinelle/errno.cocci +++ b/coccinelle/errno.cocci @@ -23,3 +23,10 @@ expression e; + return log_LEVEL_errno(e, ...); - return r; +@@ +identifier log_LEVEL_errno =~ "^log_(debug|info|notice|warning|error|emergency)_errno$"; +expression e; +@@ ++ return + log_LEVEL_errno(e, ...); +- return -e; |