From patchwork Thu Apr 16 20:16:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefano Babic X-Patchwork-Id: 1271895 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=googlegroups.com (client-ip=2a00:1450:4864:20::137; helo=mail-lf1-x137.google.com; envelope-from=swupdate+bncbcxploxj6ikrbhx24l2akgqefwdl6wa@googlegroups.com; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=googlegroups.com header.i=@googlegroups.com header.a=rsa-sha256 header.s=20161025 header.b=TacBpzjz; dkim-atps=neutral Received: from mail-lf1-x137.google.com (mail-lf1-x137.google.com [IPv6:2a00:1450:4864:20::137]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4939VB3XKdz9sPF for ; Fri, 17 Apr 2020 06:16:34 +1000 (AEST) Received: by mail-lf1-x137.google.com with SMTP id s1sf2566691lfd.16 for ; Thu, 16 Apr 2020 13:16:34 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1587068191; cv=pass; d=google.com; s=arc-20160816; b=tFuvgGjs+Tq5xMQ0PC1QDdhUMZ89C86ZHhvH6+KLKB6hlmpXeMBnuI+5wPbfTK9lcL WeRc+hEfJi7pxeQXl2bOXVnIYxnntPWa4m2Z5rIz8/2CwFG4+7ON5HMitt+U9iKKyPNh IneBhssXPT2nELNT9pNrfnmByWmcMOQt17b6MG240Q4Ex97zeHUfscOCC3jTY0js27iH vkf3LoA7G2q2F86KUGteCYivOH+/NJt7U29St4vzBfoRn2ZEPDLI1VbRBZYfB8HPco2F Da4PPALIq94x0xcTYmM4TLHReAXacw0v+cQ74nVV7rLFkMzrZTRtNtht9uNNqz4nNKBW K9OQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:sender:dkim-signature; bh=raWLFLeGEoxmeUcnHAwU3RqdGTu/rd0mzv6AIuUxOYE=; b=p7zOknalBp69Qd8HwWtj3+XI1WED0Fd8WOpEa2gngWwyYRQseXBbsuZpukKF4YE2ub A4FiOXDm9EvxL8rvdFrIPXvfRGnUfTilM54MrFH70XrdWVNvQWW5Wh07cpbbBxB1jjDI 70kJwX5xE4/E6/C+EGtlpWle7fmhmqvYVZZOAVIygkYqAKrcSzaEOJtrldRwETtHfU9Z 2/AoMl0aEltV+fs4XS2rc+KB7UxhOxOXpgbS9SFrzTZgi5y4Dit/HxuddI1J+fy4cu8W ycqn7QUd+xYlC1k6YR8iAnWyUkpnFwKAjChfnJJbOeEf/IA+DNz8dZHn0mj97VUdLyy7 jJCA== ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=neutral (google.com: 212.18.0.9 is neither permitted nor denied by best guess record for domain of sbabic@denx.de) smtp.mailfrom=sbabic@denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=raWLFLeGEoxmeUcnHAwU3RqdGTu/rd0mzv6AIuUxOYE=; b=TacBpzjzhBXo9o/4HI0enW4NDMkblKSlSMCk/furXtrdoir+h1M3jyKDbcu4EfOLAQ MMlVnuGtnZ1xJrZHddm4znwzK4jUro2Hqlk86KzhUZ8f4iP8tHI4ZSOoXLEdhROFuTAL sCBHfQja+ygTDAVL14nOjTPFTSnFwFSJboJ2N5BryLV94Rn0J738NYEYhZbE8PRP8gnw zODA3fMIqeFECLviH8BcnTGGf7ld6/rp5CauJP4NyOypDYU+hR/aSgVOvDoyHzxEGcl2 UDJ8bDq+xRGVfsOC42pj8rwLjh+VlA13I7scXoK+RlGRYwL/aOh7k1RUOGL9dc+KX1UW NWog== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:from:to:cc:subject:date:message-id :in-reply-to:references:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=raWLFLeGEoxmeUcnHAwU3RqdGTu/rd0mzv6AIuUxOYE=; b=e/TCtxc7sj9u8kKGKrviQTzL8B7G9XFZT1VnWf836rQwMU1kkZkjFu89UEh7N9maGT rMhApWs5Znu4YEEEZgP2s84kINvk+sdUVbvHoWV5u9qJYjYZd/qiXRYYnW0ENJBn+nJs qWriu3uCfNhtQeTAExg8DubX/0mOYU+kK+NyQ2ulRGH4kOPsI9w9pB7gjguTixZw5ywG ukKQnFdLIT6/EbOMMP+E9nROhjhHwBo5c+Gceek3XJBr3ZyjbrUOXE/FDP1awjcRWeyz hs9iFhlCfbLurP+Lffq5FI+q1rAm9P/Vyfmsb5F6/EjngnmlL4viclBljOSsc28Vwyrb nsfA== Sender: swupdate@googlegroups.com X-Gm-Message-State: AGi0PuY+SWCepeXk9ZonoBHzLYqZI1iJ+dV5/VgDLIPqBHvvZC9QCi9k qBdAed/9ICvfnZE1IDQ84Kg= X-Google-Smtp-Source: APiQypLT6CKWslNhU+DRRZhUcSa/l4V30+qOVnz44vqbkB8nHddRS/818+zhcpXNpkQ2YiQIrm9Rlw== X-Received: by 2002:a19:4014:: with SMTP id n20mr6736242lfa.6.1587068191117; Thu, 16 Apr 2020 13:16:31 -0700 (PDT) X-BeenThere: swupdate@googlegroups.com Received: by 2002:ac2:504c:: with SMTP id a12ls1688833lfm.8.gmail; Thu, 16 Apr 2020 13:16:30 -0700 (PDT) X-Received: by 2002:a05:6512:3049:: with SMTP id b9mr7261163lfb.176.1587068189996; Thu, 16 Apr 2020 13:16:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587068189; cv=none; d=google.com; s=arc-20160816; b=cywmgR1Tq7u6D4++oFkPhtoUKI9Lx39GOmUtHvxBVplHdaXi4vDRsn9iDUmIjNNps+ emI3FOxiYY75dGt2I63+/NBsty5KJBvg5RSLK7SRZ57sXlTXex5L3DoF14fzkTfYej1b JGGZ/QdBsAktbmbzHNUVQr3VLCPpe2mlsbILUh1uIQkYCdbUnH5CR1GMM42duWUWYQRn 1fwKKuDMPWuWJo3iZYeFG2xkNHQubl2ubhcTx/i8g8QTw9lrIM6v9arw/ELCK+X7ii1G wVjmMNJgCc7CoviLKDm3ELv65+mCU8RqPPtZmDgaDPim+DzDpTS2UBCIg9lRavqk3lTX GOjg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from; bh=tUtr7u/f9xiRVyJJD2OSzRTBru+DS2KlthYFM6iH15E=; b=vKpT+0iA42WWExv3fGTXopSFSqQHf31LsK1hu2VyMnZffWkXyg3gbdzyWIc/Hzt5nZ Indn4+BdlKcq54oX/DVh3HX/KJKhdozj23eKyJG2P4JoONO9gX9N/bluvlrzihAlADG7 Uv7Qo8qDxdbN8gF1w1eplLG9wTBV3kIFrlywZTgIZ6BWpeuV3MUdHS1U3YjX45NEvef2 luNzDP7ZjcuZZHAYlNsg9t1pcFIpSBzSWuw/ittbAtepolzc84pHQ7OilTDIerna0Qbg Cqjmy124SMCdC5Hr2kH7O6p8YsGMvHlvHGld9nVCKnaLElmu+/Y2HNCtrz3CQ5NLYvuz oX4Q== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=neutral (google.com: 212.18.0.9 is neither permitted nor denied by best guess record for domain of sbabic@denx.de) smtp.mailfrom=sbabic@denx.de Received: from mail-out.m-online.net (mail-out.m-online.net. [212.18.0.9]) by gmr-mx.google.com with ESMTPS id f25si1142353lfc.3.2020.04.16.13.16.29 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 16 Apr 2020 13:16:29 -0700 (PDT) Received-SPF: neutral (google.com: 212.18.0.9 is neither permitted nor denied by best guess record for domain of sbabic@denx.de) client-ip=212.18.0.9; Received: from frontend01.mail.m-online.net (unknown [192.168.8.182]) by mail-out.m-online.net (Postfix) with ESMTP id 4939V53bPcz1qsbG; Thu, 16 Apr 2020 22:16:29 +0200 (CEST) Received: from localhost (dynscan1.mnet-online.de [192.168.6.70]) by mail.m-online.net (Postfix) with ESMTP id 4939V53MsYz1qqkp; Thu, 16 Apr 2020 22:16:29 +0200 (CEST) X-Virus-Scanned: amavisd-new at mnet-online.de Received: from mail.mnet-online.de ([192.168.8.182]) by localhost (dynscan1.mail.m-online.net [192.168.6.70]) (amavisd-new, port 10024) with ESMTP id tq4roOJ7rn6g; Thu, 16 Apr 2020 22:16:28 +0200 (CEST) Received: from babic.homelinux.org (host-88-217-136-221.customer.m-online.net [88.217.136.221]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.mnet-online.de (Postfix) with ESMTPS; Thu, 16 Apr 2020 22:16:28 +0200 (CEST) Received: from localhost (mail.babic.homelinux.org [127.0.0.1]) by babic.homelinux.org (Postfix) with ESMTP id 64A8C4540578; Thu, 16 Apr 2020 22:16:28 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at babic.homelinux.org Received: from babic.homelinux.org ([IPv6:::1]) by localhost (mail.babic.homelinux.org [IPv6:::1]) (amavisd-new, port 10024) with ESMTP id br5yH0jbhYfz; Thu, 16 Apr 2020 22:16:25 +0200 (CEST) Received: from paperino.fritz.box (paperino.fritz.box [192.168.178.38]) by babic.homelinux.org (Postfix) with ESMTP id A0F5545406C3; Thu, 16 Apr 2020 22:16:23 +0200 (CEST) From: Stefano Babic To: swupdate@googlegroups.com Cc: Stefano Babic Subject: [swupdate] [PATCH] Fix coverity #292140 Date: Thu, 16 Apr 2020 22:16:20 +0200 Message-Id: <20200416201622.32387-3-sbabic@denx.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200416201622.32387-1-sbabic@denx.de> References: <20200416201622.32387-1-sbabic@denx.de> MIME-Version: 1.0 X-Original-Sender: sbabic@denx.de X-Original-Authentication-Results: gmr-mx.google.com; spf=neutral (google.com: 212.18.0.9 is neither permitted nor denied by best guess record for domain of sbabic@denx.de) smtp.mailfrom=sbabic@denx.de Precedence: list Mailing-list: list swupdate@googlegroups.com; contact swupdate+owners@googlegroups.com List-ID: X-Spam-Checked-In-Group: swupdate@googlegroups.com X-Google-Group-Id: 605343134186 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Signed-off-by: Stefano Babic --- ipc/progress_ipc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ipc/progress_ipc.c b/ipc/progress_ipc.c index b339def..6ab2102 100644 --- a/ipc/progress_ipc.c +++ b/ipc/progress_ipc.c @@ -42,7 +42,7 @@ static int _progress_ipc_connect(const char *socketpath, bool reconnect) int fd = socket(AF_LOCAL, SOCK_STREAM, 0); bzero(&servaddr, sizeof(servaddr)); servaddr.sun_family = AF_LOCAL; - strncpy(servaddr.sun_path, socketpath, sizeof(servaddr.sun_path)); + strncpy(servaddr.sun_path, socketpath, sizeof(servaddr.sun_path) - 1); fprintf(stdout, "Trying to connect to SWUpdate...\n");