Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp2196142pxv; Sat, 24 Jul 2021 08:16:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzbMgSKdm3Wuz04ICRSmSdgh0Cy97lJ1aZQjxM7TcuaeIu5brZJ+kAaGx0w6CXRF/GzGrjB X-Received: by 2002:a92:ce91:: with SMTP id r17mr3975853ilo.264.1627139765264; Sat, 24 Jul 2021 08:16:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627139765; cv=none; d=google.com; s=arc-20160816; b=pPkJuB364kMX4JH076RgNIrLBNRhCbWZ3DxgSS+Bq8SXk2Cimxd37pKau7xb7hBvsQ vkYiuWgSBG31D5EafOPdWmJXlzDMuMAKKPyxkYnEj4q87r5oYuugc6K2czfAyfUwDtNr T45MoHza0Pb6b4LGFHiOfHhVaUPvUyJ0Ckfk76NETnPypEUmP2UlM+XFXMYdoh/WXVBJ tnGEQVlcM9lJTe5lWSm2pIjrV3hKcvg+LP8A5lvDLpFZbJexRHjlOj9QJUCCX14rtZHR 8CHnXZXZU+gIQQz4vq6S2DNMvurNLMTosZx9GWu4yAvFq6M16w0NXq5NQF+TIDkGSVqH k59g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=TflnxdHMMaqK/dhyQLaUyDsr8bZ3GFELJDZguBwapVo=; b=yn4SH6IzTOKNvuHyFau0OtKtoDtJBIpl+xx5WAExSI32b7PvNlR/hl9tNa9a8gPoyR bHDU1IFQjbtLOmdy3MbbbZaqRrYwNfk4bEm0XuHeaIqXdy8c6EXFo8jyfuIo2rFoTinA sDzwY1esUpc+coG0FUSh5GT+FdHCuNXBfj77uOOsqXQTylio1wzQsUZC8BB/AUfYzeqw XgDYU1HaDSlSmqRtvPNd/dukyouj6eVFvq0udh9FdAAGgkxhLiJy6QUPk0LgNtfbNOux 76t5CuQ9SmfzEixvAeVg0SyQM8IYyja91JEsCOG9CpqaJ58IATlMfuhH5PRBZsbMQASf YWSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=lWuupqZv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gmx.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n23si3181723ion.23.2021.07.24.08.15.54; Sat, 24 Jul 2021 08:16:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=lWuupqZv; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gmx.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229995AbhGXOeP (ORCPT + 99 others); Sat, 24 Jul 2021 10:34:15 -0400 Received: from mout.gmx.net ([212.227.15.15]:54725 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229992AbhGXOeO (ORCPT ); Sat, 24 Jul 2021 10:34:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1627139666; bh=4noc/sQzclIW/kkrihBjzzi6QwizoNZ8djRM4lvM73g=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date; b=lWuupqZvPp60MW1gvccIpZbpV3BV0Y2OPov5Sl7JQNykMOhs0y4XHb1aDQI+3W1EK 72fg87aV0FYCm4bkVOA9evD72G4d/VsyO/Ht1TCD87QWTwuK9Kb+Dc5okPtIpoAa47 j3MOZRZoXmKxy9/DfQEYjAA37pXuK+eszRe+JCto= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from localhost.localdomain ([83.52.228.41]) by mail.gmx.net (mrgmx005 [212.227.17.184]) with ESMTPSA (Nemesis) id 1N0oBr-1lBVhf04W5-00wpiS; Sat, 24 Jul 2021 17:14:26 +0200 From: Len Baker To: Greg Kroah-Hartman Cc: Len Baker , Andy Shevchenko , Phil Reid , Geert Uytterhoeven , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org Subject: [PATCH v2 0/3] Remove all strcpy() uses Date: Sat, 24 Jul 2021 17:14:08 +0200 Message-Id: <20210724151411.9531-1-len.baker@gmx.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:CF3KTYSkqaOEngOglxyMd9EaNlUb1/dUGyEAN5GU0u03js5doC/ EM/4b9OWhbjKSd8ru2UsL197JEJVkoJ01uJW+UCo8Ib0nVE/Kjg6/LwqUCSKrPRwG8tshkb nYwzaM44pjBoeFei5eLsV4sr1WCEw82bY3EGORYXF2KyoMTwfX22dqSBeoZuYNPF0q7qS3e FkZkqVqZaZAfI7lSgoHtQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:RqDB3YaQbQo=:uDk5LDovtG0+MYOzDQ8jE0 XYwmMu2BOsBt4QV3A+LIE5bBK1CCjII05VUvqKg/Mq+SnYY15OFAcCDoU4oqr6KG4l9/SduzR oMVr2yCtPStMkFyLWSc6iLgDOCYNWC3f1Asi/OrmeHPzY29i79LYyxQMCqs/qwgp/iCo7MFwz qxBwtbbssO9Eo3VEfBuBJ7eQQ4JNYj5pf9ZWfz8+Rai4TmVKqaSidvF1DODPSaQ+G7sASDqiq yUATZhIyeyvq/syvBrhP0838+PavDK5tAmwoJOTLY4uXKjXG/p0koYD7JY/778lej8wa+FIOB tVeV20NTaqxbXR7N0EXRASQPsbEWGWIq4NbZUD4Xs84Hyp3X2dwBjrTJW7wr77Si/tAigRzT5 GEEV2vSGQ1EkakyTcgQ8p8cGXPvFK4cZ+Rg4g5h2b+Zu9CgO/Xcf9WLLVmbvHprjqdBh6jX8L fGJ9Yq0urLwgLy2KFQ06TCCtxNSmM9ImwRO7SkR19l0jyCbI8vPTA+Ptd+gjPcSnc3W12LtId 8m0vRazFbAKbllGDQIpdm1AEJbdRHHYg3TG1KPqXB04cInnWMAyFKf53abFuOzOZ5oWMHaNCV Q0nw+vpdAhASPyViMtyrZCnGw4DIzD0DYpqPHf/F0JMaMKcFXzZULFk2DukSMOIrTXfAl61uJ 6AHTitFA+GghNqzceTrTtPf9kU/TC946QIMGpLYUDpa3pLGddyamwITInCUAok2uuC6JMUVO3 Y42G7fIfR94JzSAhrE4+eoMthLKzr6Lu2n/LXhK99VIKhQ6Vo7cB8ZEXwMf1wPLRKp9fXjxd+ u3ldvZgzvpDxNDU2jn9GjlBJLbUfnbJ8bzEDA5yB2E9Bgzp+IGTLM5TwBYni4miJMaX/KUFRE ZXb7/6smxzV5yy5fXMhBUOqvpLuv6JndVpdmSkNtt5HAFhubtaqrlxr/lUK7RAuUm/9tL4BxF Uq3mrkPa7MmCoEXO5hih8fo7AKMFHzLazw9tJdlU2SVZaKDCX0+Gjnm5yDDK28cAXkoMxG1qS ZG/vDRP9unJ2v4wiNdCU4v0D+PWjeXJJ53wfspsATd9hFnYnK6Qs7LFdFU0f8wOmy4ZmxnpEo w8RBvQq3A2+RAHE6Q4cl4G8Q3dJoN1P6UY2 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org strcpy() performs no bounds checking on the destination buffer. This could result in linear overflows beyond the end of the buffer, leading to all kinds of misbehaviors. So, this serie removes all strcpy uses from the "staging/fbtft" subsystem. Also, refactor the code a bit to follow the kernel coding-style and avoid unnecessary variable initialization. Changelog v1 -> v2 - Add two new commits to clean the code. - Use the "%*ph" format specifier instead of strscpy() function (Geert Uytterhoeven) Len Baker (3): staging/fbtft: Remove all strcpy() uses staging/fbtft: Remove unnecessary variable initialization staging/fbtft: Fix braces coding style drivers/staging/fbtft/fbtft-core.c | 30 +++++++++++++----------------- 1 file changed, 13 insertions(+), 17 deletions(-) =2D- 2.25.1