From nobody Mon Feb 9 09:33:18 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; dkim=fail; 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=1567923796; cv=none; d=zoho.com; s=zohoarc; b=SWyG0ogjYrpD/0TC0FVM6a9t1zKbplz+lD2hhRcK1FwT/KYglZowKq/tr2Vt6LprOoULpQaH96xNX/rVf5nzWFZTuVwMrCLKCuWvSHNH7sqfFyiTZLJUvo58q3J/srqkQH9d198lhQ9e5PxgczDpX5qm9FMfXV0OamL7hPJqh+c= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1567923796; 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:ARC-Authentication-Results; bh=8mg012TbrBH7IitXy+GojEIbhI2BLUInMejCjfV2448=; b=LG46n8GYTwhHmmi8Rh93gR6xt6jDXKgzah/DO7+UPE2G9YS4eqm/J2QYKuAhfQ2URCnfVjpFYaxpLD4kCIL+/MmO4PSW1KQlHWtm/v4IBsNZ9KPjZDIyOISFhEBb7T5vEmNPSOc8msLCa7OBtHJ3EeUM5E6q7C9ywEIRFnorsnI= ARC-Authentication-Results: i=1; mx.zoho.com; dkim=fail; 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 1567923796191141.70305470441087; Sat, 7 Sep 2019 23:23:16 -0700 (PDT) Received: from localhost ([::1]:47210 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i6qbM-0002AK-0u for importer@patchew.org; Sun, 08 Sep 2019 02:23:08 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:41881) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1i6qUP-0002uL-0i for qemu-devel@nongnu.org; Sun, 08 Sep 2019 02:15:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1i6qUN-0002Uo-L0 for qemu-devel@nongnu.org; Sun, 08 Sep 2019 02:15:56 -0400 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]:39833) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1i6qUN-0002U5-Br for qemu-devel@nongnu.org; Sun, 08 Sep 2019 02:15:55 -0400 Received: by mail-wm1-x343.google.com with SMTP id q12so11125468wmj.4 for ; Sat, 07 Sep 2019 23:15:55 -0700 (PDT) Received: from localhost.localdomain (251.red-88-10-102.dynamicip.rima-tde.net. [88.10.102.251]) by smtp.gmail.com with ESMTPSA id g201sm15616552wmg.34.2019.09.07.23.15.53 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 07 Sep 2019 23:15:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=8mg012TbrBH7IitXy+GojEIbhI2BLUInMejCjfV2448=; b=s4p+9Lm3hwA6HUSfys6tJszvERkFrsdPkw2ttOEysl3xlZ3YYkSRid1l96IFwDnqM5 3qCiCvTYhi7NGjuNcQpRDlB80b8cAMFDDfSPcVAVOdWggW0MhuAXmbAZrnpq8qPo4rHi d8mnR5cq4BrcQ3MdJfXH9KIWVXTUVf44AyIsnoiLH6X3gmAoUOI1PNPOhcMxmQ1wLc2C nOv5fs01OyjoQPtRikIEr0Yw/lHazrXQS18sgsk/UrxpKxLY2aF/euNm9OKbC4mS6UiF HilIdeimHGuO59zDngPQdwa+YwMpdGZ0VaORrWdeU2chcy7r7fTZ8Iz46SXaoJ8RLxiJ Bpiw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:content-transfer-encoding; bh=8mg012TbrBH7IitXy+GojEIbhI2BLUInMejCjfV2448=; b=GWMYrhOy198V3ggn0631x5oz0J7j2wj47Eu7YFmdbKhY46VLH0zFlA5riyyzydXVYQ WS/Bu3LCLP9Llci+BudWSNPg0v72ALzMLcaS4BGJ8n7JoNEgdX4JM5uN9rp8xwmo01Ai d2wRPoDJ6yfg/BfdpEsNMgMYnsl4/5mR9ZpXXdmPxE7mDOZEfuTQgpxD6nmRNuv34vs2 AtWdoD7sqPKt8nECIvGhjneyrh1jId4cRgvtrTeE0HC2y8emRRQ+mC3goRvCllRXP2yq nKchE+XQSVSYFtygWDF7bH8yEsRN6JOQtJgNhORftdzZ7YFNvqZqEowx0xF96967OGA6 CkVQ== X-Gm-Message-State: APjAAAUEy6phm6Y0tObqkX9s1VCH1NcPm8vjIEriRNJ4UuS3A8SpGlrZ pCDy8+ezNud6nn3E9qwWDVRJlVsQ X-Google-Smtp-Source: APXvYqwVtAb/Z53K4q8Qmcg5QAhgZJUyZcjiXKhccz1EfVr73ilcj2fKz4USZ1sJ5bUUwvhoG12djA== X-Received: by 2002:a1c:7214:: with SMTP id n20mr12936695wmc.160.1567923354110; Sat, 07 Sep 2019 23:15:54 -0700 (PDT) From: =?UTF-8?q?Philippe=20Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Date: Sun, 8 Sep 2019 08:15:43 +0200 Message-Id: <20190908061543.25136-9-f4bug@amsat.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190908061543.25136-1-f4bug@amsat.org> References: <20190908061543.25136-1-f4bug@amsat.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::343 Subject: [Qemu-devel] [PATCH v6 8/8] linux-user/strace: Let print_sockaddr() have a 'last' argument 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: =?UTF-8?q?Guido=20G=C3=BCnther?= , 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" X-ZohoMail-DKIM: fail (Header signature does not verify) If the format is not the syscall last argument, a comma is append. Signed-off-by: Philippe Mathieu-Daud=C3=A9 Reviewed-by: Laurent Vivier --- checkpatch error: ERROR: storage class should be at the beginning of the declaration --- linux-user/strace.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/linux-user/strace.c b/linux-user/strace.c index a1e971ac8a..a297f59efd 100644 --- a/linux-user/strace.c +++ b/linux-user/strace.c @@ -67,7 +67,7 @@ UNUSED static void print_timeval(abi_ulong, int); UNUSED static void print_timezone(abi_ulong, int); UNUSED static void print_number(abi_long, int); UNUSED static void print_signal(abi_ulong, int); -UNUSED static void print_sockaddr(abi_ulong addr, abi_long addrlen); +UNUSED static void print_sockaddr(abi_ulong addr, abi_long addrlen, int); UNUSED static void print_socket_domain(int domain); UNUSED static void print_socket_type(int type); UNUSED static void print_socket_protocol(int domain, int type, int protoco= l); @@ -336,7 +336,7 @@ static void print_siginfo(const target_siginfo_t *tinfo) } =20 static void -print_sockaddr(abi_ulong addr, abi_long addrlen) +print_sockaddr(abi_ulong addr, abi_long addrlen, int last) { struct target_sockaddr *sa; int i; @@ -418,7 +418,7 @@ print_sockaddr(abi_ulong addr, abi_long addrlen) } else { print_raw_param("0x"TARGET_ABI_FMT_lx, addr, 0); } - gemu_log(", "TARGET_ABI_FMT_ld, addrlen); + gemu_log(", "TARGET_ABI_FMT_ld"%s", addrlen, get_comma(last)); } =20 static void @@ -1752,7 +1752,7 @@ static void do_print_sockaddr(const char *name, abi_l= ong arg1) =20 gemu_log("%s(", name); print_sockfd(sockfd, 0); - print_sockaddr(addr, addrlen); + print_sockaddr(addr, addrlen, 0); gemu_log(")"); } =20 @@ -1822,7 +1822,7 @@ static void do_print_msgaddr(const char *name, abi_lo= ng arg1) print_buf(msg, len, 0); print_raw_param(TARGET_ABI_FMT_ld, len, 0); print_flags(msg_flags, flags, 0); - print_sockaddr(addr, addrlen); + print_sockaddr(addr, addrlen, 0); gemu_log(")"); } =20 --=20 2.20.1