Thread (3 messages) flat view 3 messages, 2 authors, 2013-02-04

Re: [PATCH] crypto: use ERR_CAST

From: Herbert Xu <herbert@gondor.apana.org.au>
Date: 2013-02-04 13:21:47
Also in: kernel-janitors, lkml

On Tue, Jan 22, 2013 at 12:29:26PM +0100, Julia Lawall wrote:
From: Julia Lawall <redacted>

Replace PTR_ERR followed by ERR_PTR by ERR_CAST, to be more concise.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression err,x;
@@
-       err = PTR_ERR(x);
        if (IS_ERR(x))
-                return ERR_PTR(err);
+                return ERR_CAST(x);
// </smpl>

Signed-off-by: Julia Lawall <redacted>
Patch applied.  Thanks!
-- 
Email: Herbert Xu [off-list ref]
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help