]> granicus.if.org Git - strace/commitdiff
loop: remove unnecessary verbose check
authorEugene Syromyatnikov <evgsyr@gmail.com>
Sun, 1 Jan 2017 19:40:34 +0000 (22:40 +0300)
committerDmitry V. Levin <ldv@altlinux.org>
Wed, 4 Jan 2017 13:22:19 +0000 (13:22 +0000)
The verbose flag is responsible for dereferencing of addresses, and it
is perfectly handled by umove_or_printaddr; moreover, this early exit
leads to incorrect formatting of last argument.

* loop.c (loop_ioctl): Do not check verbose flag explicitly and do not
exit early if it is not set.

loop.c

diff --git a/loop.c b/loop.c
index 20e080ff4778deaabe835c064225977e0e8efef4..f19ad928c0ca31518452ad45276aba7b3dc2d697 100644 (file)
--- a/loop.c
+++ b/loop.c
@@ -160,9 +160,6 @@ MPERS_PRINTER_DECL(int, loop_ioctl,
                   struct tcb *tcp, const unsigned int code,
                   const kernel_ulong_t arg)
 {
-       if (!verbose(tcp))
-               return RVAL_DECODED;
-
        switch (code) {
        case LOOP_GET_STATUS:
                if (entering(tcp))