From patchwork Fri Feb 23 06:18:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 1903100 X-Patchwork-Delegate: zajec5@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.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=Dm7ByY65; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=nIpOAIWS; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Th0NF4SZJz23d2 for ; Fri, 23 Feb 2024 17:24:29 +1100 (AEDT) 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=8sE/1drS0Q51BMjJJwyokHiX9Cxh4GcRGvsJTiydek4=; b=Dm7ByY65Vp0ULl QPYAWKQdLlEAfEnvzNs0DZh2WCeSBaaGRgryvWklbi3j/rEX5A1EPKHt7/5QtJcUz5R0Pk+Ig1Jkv YSE6cMOpi+3PttAGWwH5EhnDmOb03DVqG9tREFqFVFDIgdSlCiDZoFTbErNb2s2uZEMgJnbEnExnx WB+cj+nGt4pU6yfZACPAA3eQEbeTYtPQXBBjneR/zXTdLPK70JCWA/ZWHNuSsP0WYNmr7rrWJzTY6 dyRWwOtWpiV24lOiwHp6qTPcsyKjgDt/Nv6WGRAbFjhVRStcdbzDUASSnRGWQ8EwLPL5e0MSmb5VW COEk8oz7qUzX05xGdhGw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOuJ-000000087Ja-0qdZ; Fri, 23 Feb 2024 06:19:42 +0000 Received: from mail-lf1-x129.google.com ([2a00:1450:4864:20::129]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOta-000000087Fw-0ESZ for openwrt-devel@lists.openwrt.org; Fri, 23 Feb 2024 06:18:58 +0000 Received: by mail-lf1-x129.google.com with SMTP id 2adb3069b0e04-512b13bf764so753998e87.0 for ; Thu, 22 Feb 2024 22:18:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708669126; x=1709273926; darn=lists.openwrt.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=KEt6zMNyiyv/CskD7+INM5RgiJKWt1uIkqJLIqgfZBc=; b=nIpOAIWSka6Iy1j8kmUO6Le1mfZDKQO6/SwvgZYMLUMpHDNgnh94WkuhKLosUCqvt8 4sCZEsUvHMu1ue8ZneOAAn4p9cIg2hndK/zkN9fB3+HxFoqA5wuKD2u8hKs6UPA/d7IH GV2BgEW4u3LUigujQRxtqE+oyarjNFKe2N+YTJP41oINJLrU6za4rN58cJ1zPc1AoET2 dSVQE1DKMdZ4jZpnAnyRctOY4FJZ8C1h0EO9IufgKzswLEYI1K3DT0fpPI8TMYiJjCu1 0/EOz0JBCI/HxZp6/ecgZ8iaoIBqGab/hElcFvVsYUZOEgy7SZSRPPBtL/tN11blIWAo P+aQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708669126; x=1709273926; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=KEt6zMNyiyv/CskD7+INM5RgiJKWt1uIkqJLIqgfZBc=; b=wMKRqD2yS++9CHjt1P0BxjgSAfV5eA8Inxd7DqA1cGTlu/YO9GN+j1Z5u4tq79smj3 o1vNqj40NoeXwrjkQFODp5G91EQfdwq5b5QAvSEyPjBdcW7J9hxygTjQc3uziX9yvmnI si984aIFXzlkQizVyw6ZIbixiFFcpa+PmzxtLkFnneObZQ57TmrdNsEYZ/oLEkgqiika RsA51DhFKlPYdBCWuN885FoV8xdodYHceZutv8Ak07SMpxjExlUcnhXy4TSZHJj44afi saEhbjzyrZbAdd0QDL7njOytbCRK/wDvaLFgwAHhe+BBO/GQcOe2F2c23KrQ0H4P45xY 9UiA== X-Gm-Message-State: AOJu0YywWOnpXcIUfBmdGXLiLnfWU1PyzWpa4z1uUf+NG1AZxBKFY5VJ 7pEgDIRDR/TWZEu74hdHcZyU0Xx/tMuXBqRaDx2fjWuqE3+IU9uEF+XCYDYh X-Google-Smtp-Source: AGHT+IHuhaMORvflXOP/Fd95d25wwLscdJEXiBByDZb83RRIZk63lRnozPjCaNSLEPzd5sT/2bjE1Q== X-Received: by 2002:a05:6512:902:b0:512:b318:c1fd with SMTP id e2-20020a056512090200b00512b318c1fdmr701558lft.54.1708669125522; Thu, 22 Feb 2024 22:18:45 -0800 (PST) Received: from localhost.lan (031011218106.poznan.vectranet.pl. [31.11.218.106]) by smtp.gmail.com with ESMTPSA id gs8-20020a1709072d0800b00a3dab486a19sm6522201ejc.118.2024.02.22.22.18.44 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 22:18:44 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: openwrt-devel@lists.openwrt.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH firmware-utils 1/4] srec2bin: drop unused "dum" variable Date: Fri, 23 Feb 2024 07:18:36 +0100 Message-Id: <20240223061839.21956-1-zajec5@gmail.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240222_221854_232623_211BEA8C X-CRM114-Status: UNSURE ( 7.95 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.0 (/) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__From=3A_Rafa=C5=82_Mi=C5=82ecki_This_f?= =?unknown-8bit?q?ixes=3A_src/srec2bin=2Ec=3A_In_function?= =?unknown-8bit?b?IOKAmGNoZWNrc3Vt4oCZOiBzcmMvc3JlYzJiaW4uYzoyOTc6Nzogd2Fy?= =?unknown-8bit?b?bmluZzogdmFyaWFibGUg4oCYZHVt4oCZIHNldCBidXQ=?= =?unknown-8bit?q?_not_used_=5B-Wunused-but-set-variable=5D_int_dum=3B_=5E=7E?= =?unknown-8bit?q?=7E_Signed-off-by=3A_Rafa=C5=82_Mi=C5=82ecki?= =?unknown-8bit?q?_---_src/srec2bin=2Ec_=7C_3_---_1_file_changed=2C_3_deletio?= =?unknown-8bit?q?ns=28-=29_?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=280=2E0_points=2C_5=2E0_req?= =?unknown-8bit?q?uired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FAU__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from_author=27s?= =?unknown-8bit?q?_domain?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID_____________Message_has_at_least_one_v?= =?unknown-8bit?q?alid_DKIM_or_DK_signature?= =?unknown-8bit?q?_0=2E1_DKIM=5FSIGNED____________Message_has_a_DKIM_or_DK_si?= =?unknown-8bit?q?gnature=2C_not_necessarily_valid?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FEF__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_envelope-from_domain?= =?unknown-8bit?q?_0=2E0_FREEMAIL=5FFROM__________Sender_email_is_commonly_ab?= =?unknown-8bit?q?used_enduser_mail_provider?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_0=2E2_FREEMAIL=5FENVFROM=5FEND=5FDIGIT_Envelope-from_freem?= =?unknown-8bit?q?ail_username_ends_in?= =?unknown-8bit?q?_digit?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_-0=2E0_RCVD=5FIN=5FDNSWL=5FNONE_____RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C_no?= =?unknown-8bit?q?_trust?= =?unknown-8bit?b?IFsyYTAwOjE0NTA6NDg2NDoyMDowOjA6MDoxMjkgbGlzdGVkIGluXQ==?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_T=5FSCC=5FBODY=5FTEXT=5FLINE___No_description_avail?= =?unknown-8bit?q?able=2E?= 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: Rafał Miłecki This fixes: src/srec2bin.c: In function ‘checksum’: src/srec2bin.c:297:7: warning: variable ‘dum’ set but not used [-Wunused-but-set-variable] int dum; ^~~ Signed-off-by: Rafał Miłecki --- src/srec2bin.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/srec2bin.c b/src/srec2bin.c index ad4222d..9a88909 100644 --- a/src/srec2bin.c +++ b/src/srec2bin.c @@ -294,7 +294,6 @@ int checksum(char *cp,int count) { char *scp; int cksum; - int dum; scp=cp; while(*scp) @@ -309,8 +308,6 @@ int checksum(char *cp,int count) while(count) { cksum += gh(scp,2); - if (count == 2) - dum = ~cksum; scp += 2; count--; } From patchwork Fri Feb 23 06:18:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 1903099 X-Patchwork-Delegate: zajec5@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Th0N21G0hz23pm for ; Fri, 23 Feb 2024 17:24:14 +1100 (AEDT) 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:References:In-Reply-To: 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: List-Owner; bh=4TOYt2s2tvlu882y8kzfj9Nwg7N83n518juEIqRZPjg=; b=Ad/bl0A1obzgWY 3kRic4JfHlYpyPPXxEZgbSd0+vVQeRu8YQiqD1Nd1QjAZplVylVIxVNtPtvGKgcEpaXRG9NXRrmTQ 3GSEJDx8E7ViKhVIS9gMIHuxEudl3yag6EQiM1pnWpvYArHAcVPITICzW/qPyhFPlrzQhTJioSwMX LwsXDbVpQeAuJhk2oh95KGsg3r5FXMlF0aT1F9mF0nqEsOTryR8sGOBAM4BYy3ZcuReZAxOJRA2+b 4SCE8SyM4VsTWcQmKbVeDQnMhu3gGEbpVbBF2xxztBacaZh8RDw/YqEd3I0DDzmoGUQ5+QwT0+3Gs bRQqo5qYdet/nhgr5mWw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOuX-000000087Md-1TG2; Fri, 23 Feb 2024 06:19:57 +0000 Received: from mail-ej1-x62a.google.com ([2a00:1450:4864:20::62a]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOtZ-000000087Fx-4BkX for openwrt-devel@lists.openwrt.org; Fri, 23 Feb 2024 06:18:58 +0000 Received: by mail-ej1-x62a.google.com with SMTP id a640c23a62f3a-a3e891b5e4eso52783366b.0 for ; Thu, 22 Feb 2024 22:18:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708669127; x=1709273927; darn=lists.openwrt.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=QFkwybAoDIoEug+LO0irnKFj3NLOQxx0Bdfxqi6etlo=; b=RVVP2nE/AElBV748U2vrR1wZ/KDgr8lxOxr57J3+CbmB33i0XN/uHRi9qajmlJSQeu sJoD48JjCmqO9Vd00zn1qrc0+zKFXK8NfXL9pc6QWwVl5f3yvTscCjnXiyh3b3h++QQB vD8qF1UbjIN94IhMe78E5bJJYho4ft/yliKJ6ExpEXrhh8uWNdTAf9MkQDbeETPhKvKx IhCZ2whG4KgAMxycSrwn2zLOJlZiSX9vFwHPnccExfk8jjMzJsrSMGO9EllUqwQ0N2te stb2hUzc4p44K0F6nV6TXwn1i+ssiMroquwhD0r+LBNz3F/JYGFP7rbAeOAKxtdrxqug JbLQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708669127; x=1709273927; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=QFkwybAoDIoEug+LO0irnKFj3NLOQxx0Bdfxqi6etlo=; b=lKzQh8FmvsC9yX1HFgPg9fje+qz0dKaSt4KKyC3DLrOIKBbNufczO5b1/7b6FFSafb gKqvxy5hGEgF7AxTNqQkyll0QmoHSwXRAvo6A7W2Fvx3q2M82HNanKooSgCciGjLiBtf GZNVYIzUKXIykhd1uEfqZQVpQI2Dcg9CrUZp8yfggacI0af0LKOgqXerln+WBt/46IsO jlTG8+VBV4eq0CPxHLHmRrcq4o5s/YGBa9oD5LifaFV8hqdI+oh+g3qunHKEkGYTyvHf BJGC0IJBrpeAbOAROc4SkO37BhJER2X+t8vo8bhYnzQCGggmixT5j+EImSs9dFFPTPe6 REIw== X-Gm-Message-State: AOJu0Yy4+6YAp4etDRK0s6P7xgF5zIO029eiyJkCNQW8hXKGa0GcR4CZ ZacuM6qf5sMwtQSGkKspchz6j0wDtn6b+S62i4GNRTUlFXX9d4EoyPemlncC X-Google-Smtp-Source: AGHT+IHrJ69cG+/HWnKqm2zDM/ecAGh7Av3AnTLvlQWPyRhUHWXAX6q/U3FGVqUAlKfL1scc46UNBw== X-Received: by 2002:a17:906:31d9:b0:a3f:b3e0:a986 with SMTP id f25-20020a17090631d900b00a3fb3e0a986mr578414ejf.72.1708669126803; Thu, 22 Feb 2024 22:18:46 -0800 (PST) Received: from localhost.lan (031011218106.poznan.vectranet.pl. [31.11.218.106]) by smtp.gmail.com with ESMTPSA id gs8-20020a1709072d0800b00a3dab486a19sm6522201ejc.118.2024.02.22.22.18.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 22:18:46 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: openwrt-devel@lists.openwrt.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH firmware-utils 2/4] uimage_sgehdr: use "char" type for header struct strings Date: Fri, 23 Feb 2024 07:18:37 +0100 Message-Id: <20240223061839.21956-2-zajec5@gmail.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20240223061839.21956-1-zajec5@gmail.com> References: <20240223061839.21956-1-zajec5@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240222_221854_161939_982D6AE8 X-CRM114-Status: GOOD ( 10.28 ) X-Spam-Score: 0.0 (/) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__From=3A_Rafa=C5=82_Mi=C5=82ecki_This_f?= =?unknown-8bit?q?ixes=3A_src/uimage=5Fsgehdr=2Ec=3A_In?= =?unknown-8bit?q?_function_=E2=80=98main=E2=80=99=3A_src/uimage=5Fsgehdr=2Ec?= =?unknown-8bit?q?=3A152=3A10=3A_warning=3A_pointer_targets?= =?unknown-8bit?q?_in_passing_argument_1_of_=E2=80=98strncpy=E2=80=99_differ_?= =?unknown-8bit?q?in_signedness_=5B-Wpointer-sign=5D?= =?unknown-8bit?b?IHN0cm5jcHkoaW1naC0+c2dlaWhfcCwgbW8gWy4uLl0g?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=280=2E0_points=2C_5=2E0_req?= =?unknown-8bit?q?uired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FAU__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from_author=27s?= =?unknown-8bit?q?_domain?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID_____________Message_has_at_least_one_v?= =?unknown-8bit?q?alid_DKIM_or_DK_signature?= =?unknown-8bit?q?_0=2E1_DKIM=5FSIGNED____________Message_has_a_DKIM_or_DK_si?= =?unknown-8bit?q?gnature=2C_not_necessarily_valid?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FEF__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_envelope-from_domain?= =?unknown-8bit?q?_0=2E0_FREEMAIL=5FFROM__________Sender_email_is_commonly_ab?= =?unknown-8bit?q?used_enduser_mail_provider?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_0=2E2_FREEMAIL=5FENVFROM=5FEND=5FDIGIT_Envelope-from_freem?= =?unknown-8bit?q?ail_username_ends_in?= =?unknown-8bit?q?_digit?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_-0=2E0_RCVD=5FIN=5FDNSWL=5FNONE_____RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C_no?= =?unknown-8bit?q?_trust?= =?unknown-8bit?b?IFsyYTAwOjE0NTA6NDg2NDoyMDowOjA6MDo2MmEgbGlzdGVkIGluXQ==?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_T=5FSCC=5FBODY=5FTEXT=5FLINE___No_description_avail?= =?unknown-8bit?q?able=2E?= 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: Rafał Miłecki This fixes: src/uimage_sgehdr.c: In function ‘main’: src/uimage_sgehdr.c:152:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_p, model, sizeof(imgh->sgeih_p)); ^~~~ src/uimage_sgehdr.c:153:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_sv, sversion, sizeof(imgh->sgeih_sv)); ^~~~ src/uimage_sgehdr.c:154:10: warning: pointer targets in passing argument 1 of ‘strncpy’ differ in signedness [-Wpointer-sign] strncpy(imgh->sgeih_hv, hversion, sizeof(imgh->sgeih_hv)); ^~~~ Signed-off-by: Rafał Miłecki --- src/uimage_sgehdr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/uimage_sgehdr.c b/src/uimage_sgehdr.c index 28143a8..6d62c04 100644 --- a/src/uimage_sgehdr.c +++ b/src/uimage_sgehdr.c @@ -40,9 +40,9 @@ struct image_header { uint8_t ih_type; /* Image Type */ uint8_t ih_comp; /* Compression Type */ uint8_t ih_name[IH_NMLEN]; /* Image Name */ - uint8_t sgeih_p[SGE_PRODUCTLEN]; /* sge_Product */ - uint8_t sgeih_sv[SGE_VERSIONLEN]; /* sge Software Version */ - uint8_t sgeih_hv[SGE_VERSIONLEN]; /* sge Hardware Version */ + char sgeih_p[SGE_PRODUCTLEN]; /* sge_Product */ + char sgeih_sv[SGE_VERSIONLEN]; /* sge Software Version */ + char sgeih_hv[SGE_VERSIONLEN]; /* sge Hardware Version */ }; From patchwork Fri Feb 23 06:18:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 1903101 X-Patchwork-Delegate: zajec5@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.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=iUOi03vh; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=IQnlWsud; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Th0NS0kTjz23d2 for ; Fri, 23 Feb 2024 17:24:40 +1100 (AEDT) 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:References:In-Reply-To: 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: List-Owner; bh=qXYe0IS95hqc46b2jAuzv1HhLcIkPA/cWm3n/fciwU4=; b=iUOi03vhM0WI/a bS654HKt45npqsvyWkgqUAtyXNyBpAMFnXZ4iCpwOJllhkyrfdp2Gv76/8injVdPTvP6svzA0pCIE 3dnvADsTD5I6uRkvx0e3OA5imxTU+CAjQeAHps472wZnZkLXS/U7ADJPYzuHCj3E2Q1qmcyW7AasZ 36B/ThUVq0oPx7xJ6RIN8eVtBMSgBqx89e2l6ZELku7xYss+u9zSpgdb0Wxwz2ywJ+A+cHP4uelmz /Zvq66uJQEV3GgaQPDFUuCnV3YTs25A/lJhTZsKn96lQ3NIj62G9gfE/hPSj0b9T1oWaPWBUDUdz6 3hyybPYf5HTl3gOHEhjw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOuO-000000087LY-1SqR; Fri, 23 Feb 2024 06:19:44 +0000 Received: from mail-ed1-x531.google.com ([2a00:1450:4864:20::531]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOtZ-000000087G0-3hjM for openwrt-devel@lists.openwrt.org; Fri, 23 Feb 2024 06:18:58 +0000 Received: by mail-ed1-x531.google.com with SMTP id 4fb4d7f45d1cf-564fc495d83so434445a12.0 for ; Thu, 22 Feb 2024 22:18:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708669128; x=1709273928; darn=lists.openwrt.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=k3bMqzWoJ1vUKR/8qAgIuiKe4UxKGcTyxyWOT+FKg84=; b=IQnlWsud04beLwE1LOicEM82vxeZBAxNkgs9t5neGI1BxjC3IhJ4dF6hxpVVcW4/05 JTaaMO35z441a8XYdtpHXJzisuc9embCPPS5gZHyRaUp2p74HsTKQIMYyWnI3XvJ6H3g t+OuSELRuJFeMIauURUoA2cCiKrwJDMGLCiwxVR/Ms01V1Brar8BhGsGRMPHvyBYeyJC sgvm9AFPaU2w/hPHEhqCSj4gERnfkfxuqVeV1ICpeIhnc0VQQtLX2kwOsJfzBGDdlHlD 4FkNFmh8NU2UFsBrsr9ksqd219HRd76KWM+nfeSEJYyN47Ivcfto1YGZqV/sAoQAr3ix G8gg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708669128; x=1709273928; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=k3bMqzWoJ1vUKR/8qAgIuiKe4UxKGcTyxyWOT+FKg84=; b=RjunWl9IhykTBOlBpQmfLp+SBhXlrvO/b3nuxQOhfN0jcVypi0Zh2HMDGG52cucRpo Eh1t/21Rp4rRrwJ1CJBWI/8qzfSWmZc3esLioKWnmkaTy+DFW+mHaD8xTC1IXaDEUujl u/plugLT5ifLRUNV31YyENfU/3tS+q6XRcjyXaod/9zqv72l16a9DehSiFWJTV45no5P BPDd5swxAitpoftuylYrSvQuaHBruE0AQBRAdzmHuNZVpjwjVdZOy+DWvPPJd2t58BNr nz8PzOkAzbqHym/oeOYabt0JHFVwhJQx56dsi23gjSxZrmFqb/sjg8pyZ0lCiYynxoH2 XF2Q== X-Gm-Message-State: AOJu0Yya8Jg/FNk1x9fK8q+jnZNwF+ZDNBbjeeEYV7p+X+wvR/hJwWQf jEc+7koHfkjSoRCaUe7m8Lblj0QzH7EKBx+wAM/Q8NupHNROVHcYdUFL8K+z X-Google-Smtp-Source: AGHT+IGlCg2ed1CGfCbgFqxCJbVgpmTHiDyesZVFd56Pe5Lqhb/5XenFEPQtn8ECGpjmgDsb386Zvw== X-Received: by 2002:a17:906:a10e:b0:a3f:8420:e291 with SMTP id t14-20020a170906a10e00b00a3f8420e291mr583396ejy.0.1708669128181; Thu, 22 Feb 2024 22:18:48 -0800 (PST) Received: from localhost.lan (031011218106.poznan.vectranet.pl. [31.11.218.106]) by smtp.gmail.com with ESMTPSA id gs8-20020a1709072d0800b00a3dab486a19sm6522201ejc.118.2024.02.22.22.18.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 22:18:47 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: openwrt-devel@lists.openwrt.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH firmware-utils 3/4] uimage_sgehdr: drop unused "ltmp" variable Date: Fri, 23 Feb 2024 07:18:38 +0100 Message-Id: <20240223061839.21956-3-zajec5@gmail.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20240223061839.21956-1-zajec5@gmail.com> References: <20240223061839.21956-1-zajec5@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240222_221854_452790_C1172BC3 X-CRM114-Status: UNSURE ( 9.14 ) X-CRM114-Notice: Please train this message. X-Spam-Score: 0.0 (/) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__From=3A_Rafa=C5=82_Mi=C5=82ecki_This_f?= =?unknown-8bit?q?ixes=3A_src/uimage=5Fsgehdr=2Ec=3A_In?= =?unknown-8bit?b?IGZ1bmN0aW9uIOKAmG1haW7igJk6IHNyYy91aW1hZ2Vfc2dlaGRyLmM6?= =?unknown-8bit?b?NzY6Njogd2FybmluZzogdW51c2VkIHZhcmlhYmxlIOKAmGx0bXDigJk=?= =?unknown-8bit?b?IFstV3VudXNlZC12YXJpYWJsZV0gaW50IGx0bXA7IF5+fn4g?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=280=2E0_points=2C_5=2E0_req?= =?unknown-8bit?q?uired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FAU__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from_author=27s?= =?unknown-8bit?q?_domain?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID_____________Message_has_at_least_one_v?= =?unknown-8bit?q?alid_DKIM_or_DK_signature?= =?unknown-8bit?q?_0=2E1_DKIM=5FSIGNED____________Message_has_a_DKIM_or_DK_si?= =?unknown-8bit?q?gnature=2C_not_necessarily_valid?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FEF__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_envelope-from_domain?= =?unknown-8bit?q?_0=2E0_FREEMAIL=5FFROM__________Sender_email_is_commonly_ab?= =?unknown-8bit?q?used_enduser_mail_provider?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_0=2E2_FREEMAIL=5FENVFROM=5FEND=5FDIGIT_Envelope-from_freem?= =?unknown-8bit?q?ail_username_ends_in?= =?unknown-8bit?q?_digit?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_-0=2E0_RCVD=5FIN=5FDNSWL=5FNONE_____RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C_no?= =?unknown-8bit?q?_trust?= =?unknown-8bit?b?IFsyYTAwOjE0NTA6NDg2NDoyMDowOjA6MDo1MzEgbGlzdGVkIGluXQ==?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_T=5FSCC=5FBODY=5FTEXT=5FLINE___No_description_avail?= =?unknown-8bit?q?able=2E?= 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: Rafał Miłecki This fixes: src/uimage_sgehdr.c: In function ‘main’: src/uimage_sgehdr.c:76:6: warning: unused variable ‘ltmp’ [-Wunused-variable] int ltmp; ^~~~ Signed-off-by: Rafał Miłecki --- src/uimage_sgehdr.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/uimage_sgehdr.c b/src/uimage_sgehdr.c index 6d62c04..c15243e 100644 --- a/src/uimage_sgehdr.c +++ b/src/uimage_sgehdr.c @@ -73,7 +73,6 @@ int main(int argc, char *argv[]) char *hversion = NULL; char *sversion = NULL; int padsz = IH_PAD_BYTES; - int ltmp; while ((opt = getopt(argc, argv, "i:o:m:h:s:")) != -1) { switch (opt) { From patchwork Fri Feb 23 06:18:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= X-Patchwork-Id: 1903098 X-Patchwork-Delegate: zajec5@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=lists.openwrt.org (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org; envelope-from=openwrt-devel-bounces+incoming=patchwork.ozlabs.org@lists.openwrt.org; receiver=patchwork.ozlabs.org) Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Th0N16Xj2z23d2 for ; Fri, 23 Feb 2024 17:24:13 +1100 (AEDT) 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:References:In-Reply-To: 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: List-Owner; bh=8xZfVCTys5tSDJGtJfnZhvKpsfvjD58EY40PIdjoZkQ=; b=CQdnB3MIwNbG9u ctYFuQKo0iE4uia67kU7FUrrhtOyQq6EerdESplWEtIF98EbI51H8fORRBPRfdVpqgIF2e2u7gvbW dGWutXyMqpifTxXoF7olo6L0CynePeJVQwSIKicrYc8AYB9QzL7bzDLZeTzWSxToEU/UPUCTpK+/3 LLvCN8sbB9T8M+VrLJ2iWXPJpoDLN1lZ+4MHQF9WP03RxP/c8wpZ9u6oYfb1gJUcX516wj0bwt64G UnHWJlyWuOdvS9dEuf4GOgSiwJs0I/KkyhCTCbHhr3e6hVh6Anpo0cfS0Um2b6G+SIzbHkD+dJ8Nw cuVGbVzMZh+++O+sbe0g==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOuP-000000087Lq-3ATM; Fri, 23 Feb 2024 06:19:45 +0000 Received: from mail-ej1-x62e.google.com ([2a00:1450:4864:20::62e]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rdOta-000000087G1-0DR6 for openwrt-devel@lists.openwrt.org; Fri, 23 Feb 2024 06:18:58 +0000 Received: by mail-ej1-x62e.google.com with SMTP id a640c23a62f3a-a3f5808b0dfso59278666b.1 for ; Thu, 22 Feb 2024 22:18:50 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1708669129; x=1709273929; darn=lists.openwrt.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=/hajE1mYaVttzUPqwLP4pp5Qs5efTexrstUWZelaho8=; b=Em90PrIhbd51qEJ7Cp9W39BILX53F9uxZvtxXzxSHR7KRoScISeVEPMB/GgG7sF3wZ soZH1u3VoludhEKus/GO8+Vg2McyY7Ut3Q9+gvgLXgtERauMvq7kUXi3j5x6W5EXUS86 j6pFP3mt5hAkwAD3KTbsqXYUj0Z65FdCJwaPGCTfkEVWWmnqvDg79PJ8zmTVgwPg68Jp 51PYO8qnPxOMn6TePULCL769+5UdYKGEc+cF2vYmFQmh+V2+mLbFfcSWqU7K6zO03vpt a/PVmFdyB+m0aDPjgTtpl+LSCz+Olx4w/Qz+gnCBywDv9sKs4aZqFrvUPjiG76b+hq7q WWfw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1708669129; x=1709273929; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/hajE1mYaVttzUPqwLP4pp5Qs5efTexrstUWZelaho8=; b=OzPdhnQbWC4KdctiCEkvkk0arGb5XgyoUFATtdZ+snbFdzBimC2Vd30nVaxCk23W7I Q+d06NUMVqnh6eHXoTRFWZH8mAPOpxyHFOPlKqhuvhRptjPTE8atP1eEiGyWVKvFWooz u9+CehkkeCBOKz1hJsh57CkUnxc8XUnVkZVB0fPRvyi1anhQx6eToI82EjWNKYwOdbFY k/Je2Jzwgg10t1rqVu19hPqlVvdGyrlYXwfNe1FR/myisoOSgC/aFLDGfQEvNgDx60ah lHtDhVjemTy927edjKHd+5FDQ1sikd9xELP11+fjTYkwP9ajDc/Y4UELCq/ipw7JBUx9 3IDA== X-Gm-Message-State: AOJu0YyCc+u6Mms/Asf4yAj9OLT3PJBr5107+LGKQryYp4PWeu91i+cY xonvVyjXbgZzYpnK6pxTua+NX5/Hxqq5EvvzE35DcFx8FO1DTVXyuwQweZdg X-Google-Smtp-Source: AGHT+IGFjJZlYIGInrdnHqDe54Tc/bwtYkXvQjGcmUCQOF7KoqYko3CBVkwFgb5yNQkImwLy3A4cJA== X-Received: by 2002:a17:906:d8d1:b0:a3e:526c:3516 with SMTP id re17-20020a170906d8d100b00a3e526c3516mr486262ejb.77.1708669129331; Thu, 22 Feb 2024 22:18:49 -0800 (PST) Received: from localhost.lan (031011218106.poznan.vectranet.pl. [31.11.218.106]) by smtp.gmail.com with ESMTPSA id gs8-20020a1709072d0800b00a3dab486a19sm6522201ejc.118.2024.02.22.22.18.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 22:18:49 -0800 (PST) From: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= To: openwrt-devel@lists.openwrt.org Cc: =?utf-8?b?UmFmYcWCIE1pxYJlY2tp?= Subject: [PATCH firmware-utils 4/4] pc1crypt: make decrypt/encrypt functions take void * as argument Date: Fri, 23 Feb 2024 07:18:39 +0100 Message-Id: <20240223061839.21956-4-zajec5@gmail.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20240223061839.21956-1-zajec5@gmail.com> References: <20240223061839.21956-1-zajec5@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240222_221854_453436_BFFD5C8D X-CRM114-Status: GOOD ( 10.89 ) X-Spam-Score: 0.0 (/) X-Spam-Report: =?unknown-8bit?q?Spam_detection_software=2C_running_on_the_sy?= =?unknown-8bit?q?stem_=22bombadil=2Einfradead=2Eorg=22=2C?= =?unknown-8bit?q?_has_NOT_identified_this_incoming_email_as_spam=2E__The_ori?= =?unknown-8bit?q?ginal?= =?unknown-8bit?q?_message_has_been_attached_to_this_so_you_can_view_it_or_la?= =?unknown-8bit?q?bel?= =?unknown-8bit?q?_similar_future_email=2E__If_you_have_any_questions=2C_see?= =?unknown-8bit?q?_the_administrator_of_that_system_for_details=2E?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_preview=3A__From=3A_Rafa=C5=82_Mi=C5=82ecki_Make_t?= =?unknown-8bit?q?hem_more_generic_regarding_accepted?= =?unknown-8bit?q?_data_buffers=2E_This_fixes=3A_?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_Content_analysis_details=3A___=280=2E0_points=2C_5=2E0_req?= =?unknown-8bit?q?uired=29?= =?unknown-8bit?q?_?= =?unknown-8bit?q?_pts_rule_name______________description?= =?unknown-8bit?q?_----_----------------------_------------------------------?= =?unknown-8bit?q?--------------------?= =?unknown-8bit?q?_0=2E0_SPF=5FHELO=5FNONE__________SPF=3A_HELO_does_not_publ?= =?unknown-8bit?q?ish_an_SPF_Record?= =?unknown-8bit?q?_-0=2E0_SPF=5FPASS_______________SPF=3A_sender_matches_SPF_?= =?unknown-8bit?q?record?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FAU__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from_author=27s?= =?unknown-8bit?q?_domain?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID_____________Message_has_at_least_one_v?= =?unknown-8bit?q?alid_DKIM_or_DK_signature?= =?unknown-8bit?q?_0=2E1_DKIM=5FSIGNED____________Message_has_a_DKIM_or_DK_si?= =?unknown-8bit?q?gnature=2C_not_necessarily_valid?= =?unknown-8bit?q?_-0=2E1_DKIM=5FVALID=5FEF__________Message_has_a_valid_DKIM?= =?unknown-8bit?q?_or_DK_signature_from?= =?unknown-8bit?q?_envelope-from_domain?= =?unknown-8bit?q?_0=2E0_FREEMAIL=5FFROM__________Sender_email_is_commonly_ab?= =?unknown-8bit?q?used_enduser_mail_provider?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_0=2E2_FREEMAIL=5FENVFROM=5FEND=5FDIGIT_Envelope-from_freem?= =?unknown-8bit?q?ail_username_ends_in?= =?unknown-8bit?q?_digit?= =?unknown-8bit?q?_=5Bzajec5=28at=29gmail=2Ecom=5D?= =?unknown-8bit?q?_-0=2E0_RCVD=5FIN=5FDNSWL=5FNONE_____RBL=3A_Sender_listed_a?= =?unknown-8bit?q?t_https=3A//www=2Ednswl=2Eorg/=2C_no?= =?unknown-8bit?q?_trust?= =?unknown-8bit?b?IFsyYTAwOjE0NTA6NDg2NDoyMDowOjA6MDo2MmUgbGlzdGVkIGluXQ==?= =?unknown-8bit?b?IFtsaXN0LmRuc3dsLm9yZ10=?= =?unknown-8bit?q?_-0=2E0_T=5FSCC=5FBODY=5FTEXT=5FLINE___No_description_avail?= =?unknown-8bit?q?able=2E?= 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: Rafał Miłecki Make them more generic regarding accepted data buffers. This fixes: src/pc1crypt.c: In function ‘main’: src/pc1crypt.c:322:26: warning: pointer targets in passing argument 2 of ‘pc1_decrypt_buf’ differ in signedness [-Wpointer-sign] pc1_decrypt_buf(&pc1, buf, datalen); ^~~ src/pc1crypt.c:324:26: warning: pointer targets in passing argument 2 of ‘pc1_encrypt_buf’ differ in signedness [-Wpointer-sign] pc1_encrypt_buf(&pc1, buf, datalen); ^~~ Signed-off-by: Rafał Miłecki --- src/pc1crypt.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pc1crypt.c b/src/pc1crypt.c index be1038b..458c234 100644 --- a/src/pc1crypt.c +++ b/src/pc1crypt.c @@ -167,18 +167,18 @@ static void pc1_init(struct pc1_ctx *pc1) strcpy(pc1->cle, "Remsaalps!123456"); } -static void pc1_decrypt_buf(struct pc1_ctx *pc1, unsigned char *buf, - unsigned len) +static void pc1_decrypt_buf(struct pc1_ctx *pc1, void *data, unsigned len) { + unsigned char *buf = data; unsigned i; for (i = 0; i < len; i++) buf[i] = pc1_decrypt(pc1, buf[i]); } -static void pc1_encrypt_buf(struct pc1_ctx *pc1, unsigned char *buf, - unsigned len) +static void pc1_encrypt_buf(struct pc1_ctx *pc1, void *data, unsigned len) { + unsigned char *buf = data; unsigned i; for (i = 0; i < len; i++)