From patchwork Thu May 19 12:48:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christian Marangi X-Patchwork-Id: 1633201 X-Patchwork-Delegate: ansuelsmth@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; secure) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=LwUzClMU; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20210112 header.b=oEH+K5V/; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:e::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4L3qVk5QzMz9vDh for ; Thu, 19 May 2022 22:51:42 +1000 (AEST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject:Cc :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=6l7+A0NELvUhHrsakaDJ8cg615nlFFG8Z5lW8QbLyeM=; b=LwUzClMUjyyTTm PM5N1amPjcHrxSXhH1bKqOiZwE5kbtKrhDZ54JrsXEyTBAHVOngCJB0SAcPgdErBZ/JdqlaU1mE11 0pzZxpLmp7yaTZCxzdWCuupIh1OYgDtdeQxpTsZBaMVVV7RtkkDtFXWHVv8Q6Ec/2MTZJHl3iqukQ uKDNYuDZINhJ3MKiuWu9aFr6Gm9gaLVj3XVYZxGYZBM32aLOFIgrCEVjP97+xMCd6M0ZOB0PKVxNx Du6B8UJnrAMG5HBmCETfNtDGRS6i21tDyHCeImS5c4kVhJ4HNz/VGN2BuvU22ur8RpA/BBpnmrSTK NHcX9nD/78B2G4uvCdzQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nrfap-006l8W-EA; Thu, 19 May 2022 12:49:27 +0000 Received: from mail-wm1-x333.google.com ([2a00:1450:4864:20::333]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nrfam-006l81-7L for openwrt-devel@lists.openwrt.org; Thu, 19 May 2022 12:49:25 +0000 Received: by mail-wm1-x333.google.com with SMTP id bg25so2817636wmb.4 for ; Thu, 19 May 2022 05:49:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=nI7frhSXyg86bp9OHkrqnj5DKRcqdqL7sCAuTuY2hD0=; b=oEH+K5V/xNcKYobJ4RRkOwf1EfgmDwmL7FCRwxdbp1d8gwNuAwl9tSqygjay6Vzxa1 F4ICXnKifFPVwmQEb5gWCZL2eRZAT4kVAdr6unFVWdVs+wjpF4slvTGKV4kWiad6bxJh OYVrWUWCQscNP3bJVqn1e4qs6gz/by13x4LLTxUZjJIgz04dTMCS3WUWNd1mg+lm62RM OZbz764VvSR0mCYo1iGzh3qExmy7xp9NNsXmR9PI5z/4UnW4SafWOBNdl+9SZw5k4j51 jocNnS0jsT9j80OhQ32qz54aErgvfke+fukoiMSYcbnhAUPOoUCehoMZHj8TMd7clEaq ix3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=nI7frhSXyg86bp9OHkrqnj5DKRcqdqL7sCAuTuY2hD0=; b=bwIq/bFeK4XF/wK0SSTrv4GKhpbsFrAuWj4EmB9/UCQy+gm7NRU1wvelhausdIBEtK WRgAhLPkl4t70slCRPVyiVi6wROsEn6yr+UWo2z1wU2NDSu+CGDPugga8Dq+PLYtwljO oYKgtbvAfR9yiB5wL8HUD6DPHGYwLVFUS7yk/aHBEBlwbWZ2BP7TIO4RGYZX/4iWp7H/ moci7VrEvMA3HRuvmi3zhA8DRn2bAxYJ2CTJelJHjvqjNa3Rufq5d6s/8Yvhhe8ww0kP EtCFIw5UWOtR6lutg4kZO1gsHMAKMQeGcPGYc811Cqh80CEaYJ8eAYyOnnn228cDEaf6 MT0w== X-Gm-Message-State: AOAM533aGj1m00NG2NGHmYfCw6qCUpKNMnqOjCr52BifmEbdJ3/xAcTh z1BpvVUDNWezkbEQvIbpHnuFPP68hJA= X-Google-Smtp-Source: ABdhPJyhqSIiePbsMblAFLwrIKEVrBT3l6VmFehlOK4+LlaKRNcqEwppG3n94G1fiH+0guxnoVOy8g== X-Received: by 2002:a05:600c:4346:b0:394:1a53:c8ba with SMTP id r6-20020a05600c434600b003941a53c8bamr4190190wme.173.1652964560091; Thu, 19 May 2022 05:49:20 -0700 (PDT) Received: from localhost.localdomain (93-42-70-190.ip85.fastwebnet.it. [93.42.70.190]) by smtp.googlemail.com with ESMTPSA id j35-20020a05600c1c2300b00397220a9354sm3702908wms.30.2022.05.19.05.49.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 19 May 2022 05:49:19 -0700 (PDT) From: Ansuel Smith To: OpenWrt Development List Cc: Christian 'Ansuel' Marangi Subject: [rpcd PATCH] iwinfo: fix compilation error with GCC 12 Date: Thu, 19 May 2022 14:48:39 +0200 Message-Id: <20220519124839.11797-1-ansuelsmth@gmail.com> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220519_054924_321506_7CC707B2 X-CRM114-Status: GOOD ( 12.77 ) X-Spam-Score: -0.2 (/) X-Spam-Report: Spam detection software, running on the system "bombadil.infradead.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: From: Christian 'Ansuel' Marangi Fix compilation error with GCC 12. In file included from /home/ansuel/openwrt/staging_dir/target-aarch64_cortex-a53_musl/usr/include/libubus.h:23, from iwinfo.c:21: In function 'blobmsg_close_array', inlined from 'rpc_iwinfo_assoclist' [...] Content analysis details: (-0.2 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no trust [2a00:1450:4864:20:0:0:0:333 listed in] [list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [ansuelsmth[at]gmail.com] -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's domain -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature 0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily valid -0.1 DKIM_VALID_EF Message has a valid DKIM or DK signature from envelope-from domain X-BeenThere: openwrt-devel@lists.openwrt.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: OpenWrt Development List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "openwrt-devel" Errors-To: openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org From: Christian 'Ansuel' Marangi Fix compilation error with GCC 12. In file included from /home/ansuel/openwrt/staging_dir/target-aarch64_cortex-a53_musl/usr/include/libubus.h:23, from iwinfo.c:21: In function 'blobmsg_close_array', inlined from 'rpc_iwinfo_assoclist' at iwinfo.c:643:3: /home/ansuel/openwrt/staging_dir/target-aarch64_cortex-a53_musl/usr/include/libubox/blobmsg.h:250:9: error: 'c' may be used uninitialized [-Werror=maybe-uninitialized] 250 | blob_nest_end(buf, cookie); | ^~~~~~~~~~~~~~~~~~~~~~~~~~ iwinfo.c: In function 'rpc_iwinfo_assoclist': iwinfo.c:564:15: note: 'c' was declared here 564 | void *c, *d, *e; | ^ cc1: all warnings being treated as errors ninja: build stopped: subcommand failed. Signed-off-by: Christian 'Ansuel' Marangi --- iwinfo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/iwinfo.c b/iwinfo.c index 6c0319e..38484c8 100644 --- a/iwinfo.c +++ b/iwinfo.c @@ -561,7 +561,7 @@ rpc_iwinfo_assoclist(struct ubus_context *ctx, struct ubus_object *obj, char res[IWINFO_BUFSIZE]; struct iwinfo_assoclist_entry *a; struct ether_addr *macaddr = NULL; - void *c, *d, *e; + void *c = NULL, *d, *e; struct blob_attr *tb[__RPC_A_MAX]; bool found = false;