commit | 01e97e6517053d7c0b9af5248e944a9209909cf5 | [log] [tgz] |
---|---|---|
author | Al Viro <viro@zeniv.linux.org.uk> | Mon Dec 15 21:39:31 2014 -0500 |
committer | Al Viro <viro@zeniv.linux.org.uk> | Sat Apr 11 15:53:35 2015 -0400 |
tree | 30f57eededa62a390543b3a596d81006deb22384 | |
parent | a2dd3793a1c3ac709f1d7b48ad7751563f4c654f [diff] [blame] |
new helper: msg_data_left() convert open-coded instances Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
diff --git a/crypto/algif_hash.c b/crypto/algif_hash.c index 0a465e0..1396ad0 100644 --- a/crypto/algif_hash.c +++ b/crypto/algif_hash.c
@@ -56,8 +56,8 @@ ctx->more = 0; - while (iov_iter_count(&msg->msg_iter)) { - int len = iov_iter_count(&msg->msg_iter); + while (msg_data_left(msg)) { + int len = msg_data_left(msg); if (len > limit) len = limit;