From nobody Tue Feb 10 23:55:15 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org ARC-Seal: i=1; a=rsa-sha256; t=1571732434; cv=none; d=zoho.com; s=zohoarc; b=CkMChxsgrL6cY+LWhFOQGMCokCNE0qfIqhHnamaRlXNzycDOo2L7aFbl6DwkP9BJYXkLxXKUlbp0lpsv6q/btB1P+3f+eeP+isS2kPt9wf8w5CQmU4z6h76Ch4vmEsw+fAOd7lONi8XZimGT7p+dvM+vXQpd9myeDc8bMwSTjpI= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1571732434; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=M7Ct6H4q0SYFaf+WFg8KVqsmscz4qSkzYVBVNWSMptc=; b=SFyCsaSOrAhmiMhk4A23KzOqe9wfCSliTMO6usrBSyFV+6+l44kW6jMKJep2uxW0ZDCNUOe4iPCsZxZhY/lA0M8WtMOYg/fCY2f1TNS92EJZO2PQT+P24MMRN2YCIVLAWJZ2YX6XuRx91TK6YhJwmuifEHFk4sDL90S9n4wwbFE= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1571732434527909.2739926247012; Tue, 22 Oct 2019 01:20:34 -0700 (PDT) Received: from localhost ([::1]:51470 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iMpP7-0003fW-0D for importer@patchew.org; Tue, 22 Oct 2019 04:20:33 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:44259) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iMpGP-0002y8-O7 for qemu-devel@nongnu.org; Tue, 22 Oct 2019 04:11:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iMpGO-0005AT-KD for qemu-devel@nongnu.org; Tue, 22 Oct 2019 04:11:33 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:45923) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iMpGO-00059Y-AX for qemu-devel@nongnu.org; Tue, 22 Oct 2019 04:11:32 -0400 Received: from localhost.localdomain ([78.238.229.36]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.183]) with ESMTPSA (Nemesis) id 1Mtfa5-1i1a142DB1-00v9j3; Tue, 22 Oct 2019 10:11:17 +0200 From: Laurent Vivier To: qemu-devel@nongnu.org Subject: [PULL 03/11] linux-user/strace: Display invalid pointer in print_timeval() Date: Tue, 22 Oct 2019 10:10:56 +0200 Message-Id: <20191022081104.11814-4-laurent@vivier.eu> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20191022081104.11814-1-laurent@vivier.eu> References: <20191022081104.11814-1-laurent@vivier.eu> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:hCOy3gVybWU6TYPsuvud3YzUqA4Ytz+yHtzWQrt54XaYdteppXq 9xx9V/RI1sTN2tMjOsKXQfnV+/crOL3GF9IxLzkMM/HbEtXwiMSfCmSaKUxX+DXzGDPS4E2 1NnVhpNXUGeY5srrB6dHLmTxtPvdwk67SZZp7EMvuCzWyjWEpYGGUC3To7RMOtMqKjCpr7K yhgDPHl//R07GQqOO6U4w== X-UI-Out-Filterresults: notjunk:1;V03:K0:6MCORydexKE=:lE/nrl3vGZrjsjebIVGAdb /9bwsm8PQX5KjkpCJwEKIot5c4raIjsfLm48CQMDgKJMfIjywhpV7vY3JnCK8sZs5YW+/57A9 O37NK4jhOiwODyU0THn/PuDYGJVvyRX32mvxMDHxatWTDKlldsbL1eOIYqbEsLlmoVLegAVod Gc7a6BKYjY4Zo2wFFubf6Jg2zIOe+LSF6ohwZkaelo2SrLjFqzbUGE+B5ERiUxzSJEoxfJjWw Mhhhip+//JL+Q8qMSv6mfIHnCdoLgHDoh7wE/ETtRAxrcWTpd9joD3G1hjhLOvW56U8/jf2Tg KVFG6qhUHezFoEu8/Ky1056zbwGWJKUwsA70jCqKclUzen3fuP8keBcQLgoTWeZ747t962YvC KgDa8kq64fTCEYc7PfGcOG35GECBexJ2AyMKn44baq/XoC6/c3DPNCkI8RowT9Kw+3emYbx+d HZldae0fAFSJ3OIcCcfYkLoTQGZ85IxbwTSaM/L39iA+MFGrhDc8gXpClsRp5or6CQSGHwB7q n1xN7hqIvKJr1fy6+NynkhXntkg7Bmcdw+s3qPG2CMVABtOeNZk0IK4fcDKVN8HwwwE/Vbj0a 8dLze+xko1IyTIG8KG0i+v5xGBzUqfS1Re8DjOlXZ7Mr8DsrB120+7UdN7u0MvrjngtTQpBHz BgG++bnSS8g6HWrC4AwNjW4JpfiYvqO87ogLavHvLsCgNBP+PFs7KhvUjofINnvgQ7qxmmI0e lxaZyz5Gyf2NQnkbmZpemMlDDXZBA6prxWV6DMo9Y9VkckhxleN2zlku9IGlmOmOxWMUVN32x 2nrbmm6u74k5APQgOXalC1oLZqU/VppYTEXEXCUo/QNDX33iI2Zasrq1GVWfzgDF8IZYrUkEK H/lRD4eNTOQAqFyC/Io3UerXr+Z7Oya0TtG5o9QE0= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 217.72.192.74 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Riku Voipio , Laurent Vivier , =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" From: Philippe Mathieu-Daud=C3=A9 Suggested-by: Laurent Vivier Reviewed-by: Laurent Vivier Signed-off-by: Philippe Mathieu-Daud=C3=A9 Message-Id: <20191021114857.20538-2-f4bug@amsat.org> Signed-off-by: Laurent Vivier --- linux-user/strace.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index c80e93b5db8a..f326c357a26d 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -1243,8 +1243,10 @@ print_timeval(abi_ulong tv_addr, int last) struct target_timeval *tv; =20 tv =3D lock_user(VERIFY_READ, tv_addr, sizeof(*tv), 1); - if (!tv) + if (!tv) { + print_pointer(tv_addr, last); return; + } gemu_log("{" TARGET_ABI_FMT_ld "," TARGET_ABI_FMT_ld "}%s", tswapal(tv->tv_sec), tswapal(tv->tv_usec), get_comma(last)); unlock_user(tv, tv_addr, 0); --=20 2.21.0