This makes the return value match the comment. Previously it would actually return 0 if encryption was successful. (No callers currently care.)
Signed-off-by: Eric Biggers <[email protected]> --- fs/crypto/fname.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/fs/crypto/fname.c b/fs/crypto/fname.c index e5c6959..5b10b73 100644 --- a/fs/crypto/fname.c +++ b/fs/crypto/fname.c @@ -100,12 +100,13 @@ static int fname_encrypt(struct inode *inode, } kfree(alloc_buf); skcipher_request_free(req); - if (res < 0) + if (res < 0) { printk_ratelimited(KERN_ERR "%s: Error (error code %d)\n", __func__, res); - + return res; + } oname->len = ciphertext_len; - return res; + return ciphertext_len; } /* -- 2.7.4 ------------------------------------------------------------------------------ Transform Data into Opportunity. Accelerate data analysis in your applications with Intel Data Analytics Acceleration Library. Click to learn more. http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140 _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
