Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp585780imm; Sat, 14 Jul 2018 07:36:12 -0700 (PDT) X-Google-Smtp-Source: AAOMgpe+4h8hmz6tPX5CjNd6rUP9TU9R1A37ARYGDrmuptChWez/bZGNCinFV3FBhbGFHWcR4XJl X-Received: by 2002:a17:902:bd97:: with SMTP id q23-v6mr10256411pls.238.1531578972767; Sat, 14 Jul 2018 07:36:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531578972; cv=none; d=google.com; s=arc-20160816; b=V4N3/ruzyV69dmieDfF17hpV0iQZNmjSYDXPBycfkOtpXVc3uabrj1X/bKB+AGkn69 Lgj90sBQlqvhObn6ff9YJkMKQ+P5HMUeE4fP2Pw+9PvU5seCIb/XxwxdQ3js8eIyA5Ra LS2Mdku1/UGmkEl/qi0Ztv+ytwlegun6Kjh1gT3WM8yyoSeJOdsf2nKqrGnypxDnStwW O5vqi1TwJZWlzND+TQ/t42azSCGEZKnZUuFvSVzznbERjk11NBfyDTEjXWwrXLoQiQVL iARgfvRNZfK18C7pLrsxPk0Gg04OAIawTGoi+ygVCZl8FQdo3GHqaALxgIga8I5uON3O fF2w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:subject:references:cc:to:arc-authentication-results; bh=/HMjSxziCLz/dcpmJyD570eKYMaxuYsPVRZW/DNSfeU=; b=plY+HfrOP8Fc/kdH32mP0K+ofH3GJQ3Yu1RYgHpIeZaljgZsBoTRWPeQfFf4k4eNb2 VA5APR0TBYSj1DG73lzkJsEeTkDTg6XVsNi2dp/oekH9UfcJ8oqJ2PQlOnOhborYiUdJ Dz2C0gbE90EE0jx1qJc06cqP2Y7XH8fUnu1H5yf3njhG7cfiYPYmoIbi4n10yurJGQmo AvDiTwoNDeF1PaT4AySkP9jUD8la8PEZK0G70Aw/+2WwBynt+HDfSH3VagAo4qEIs79b 4ooaWXrPIeNKl8oPI0Zs3wsfezm92bFs9uAHwPZorN8v7mH7ud9UzmnL+VPg8wIG+q2k 8OZw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=sourceforge.net Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o184-v6si24346989pga.520.2018.07.14.07.35.57; Sat, 14 Jul 2018 07:36:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=sourceforge.net Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727855AbeGNOyd (ORCPT + 99 others); Sat, 14 Jul 2018 10:54:33 -0400 Received: from mout.web.de ([212.227.15.3]:57553 "EHLO mout.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726793AbeGNOyd (ORCPT ); Sat, 14 Jul 2018 10:54:33 -0400 Received: from [192.168.1.3] ([92.228.101.215]) by smtp.web.de (mrweb002 [213.165.67.108]) with ESMTPSA (Nemesis) id 0Ma2hT-1fLRCy1PGJ-00LrFn; Sat, 14 Jul 2018 16:35:03 +0200 To: Dominique Martinet , Julia Lawall , Masahiro Yamada , kernel-janitors@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Coccinelle , Gilles Muller , Michal Marek , Nicolas Palix , =?UTF-8?B?VmlsbGUgU3lyasOkbMOk?= References: <1531555951-9627-1-git-send-email-asmadeus@codewreck.org> Subject: Re: [v2] Coccinelle: Replace strncpy() + truncation by strscpy() From: SF Markus Elfring Message-ID: <4bbe41a6-a9c6-ddd7-6683-14c792c16de0@users.sourceforge.net> Date: Sat, 14 Jul 2018 16:34:55 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <1531555951-9627-1-git-send-email-asmadeus@codewreck.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-GB Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K1:v8G0uByQ6MMIcIv5Ii3X0/k6ofGcuu1dpMKNUaCljXuExYXIww4 BnDLt4DdhvkRMmiQD2gYyJz9MMLlqwnKIhZKdHS9MZaEgVx7ORvN73Le/OxC9i/fhiAf6kL vdxBee9DROH5Z4ciB12jAo1rsEtd1GahA7mMPL0sRCoByVFrRUkWk7o+A57vygmhB9ZdAF8 4O/r6JAtics7NosLHtMWQ== X-UI-Out-Filterresults: notjunk:1;V01:K0:F/ONM8SBmAA=:LS+FCbzk5COUf/VsWym3vH sj974RgE/FXexJhfIDJaor4TbPROL60YWUuSn8aH8jqbpsmzX55AZh5T5DmW/44tWO7bvQ2tz ijP0L5qTjlWBhFWPubrWDyZfUs3YA9fnfsaYRo2YAfiYnEZNeGpWqpENMhVb8PtoG/Bf8XKcL ddjIL2sUYg4ZAvNcJ7tkMZ7x1VCFuiWNK4BR0zbaq8iMQTtz4ylPhD8pMVhOVqyi4jyR4wMTR Sw/tb7M3tvtwWHhAF8RGlHAJSsSWjhXe9SRAXQvNRhPGmEFx/KMkeTfXhvVoK4yRdaDXSHXCS iShpT16UvzU3DwqWWNwggtfO2t0HdQBGbMkjIO4Ch9R4aqZ45+5U2mQ2t82lbzGPi1IxEnZrr XRwMFVyqQOOkBdrHVkYKCZk1/0jkykfJuforeYDaHYIG9zmP5Zjd062Mu1bYJ+pgvb1Cgvvb7 vn1vjGRaK1LIJ2CEH0qagn5JvreS+xvzeExK9uQy3hxC9eYH35bnYJdLrjeaRgFxscV6E/6Q0 8qvjGtxdBtgwCbuYzlcgADkWnpkkvtWetbCejwRyf0o8aNehamqKWl6unowCi5vuXYO9gwmF7 EEwc2oW3QUfexmmTz/gAHkCkgUOR4KOMyjeQd2Dfk42b9P694sKn5SK4fu0QLAKHsZHX9LQk5 nwLdNoUgsej/0T6SYmrV+Akg+yB3yEuVHeHRDZseWuiKpKiuifUtuOE5BEG8Yj1zDwg2OHlO0 /auMsJIgTHLp1ZjtEpqkZFf14h4eGpU0sHEB1O5yRBJrpcQ4OOtxmMiXNH4TQ6CRCsuWbMWmd TMf+zZ0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org I would like to contribute another bit of patch review for your proposal. https://patchwork.kernel.org/patch/10524633/ https://lore.kernel.org/lkml/1531555951-9627-1-git-send-email-asmadeus@codewreck.org/ * I have noticed that an action word was missing in the commit subject. * The commit description was started with the wording “Besides being simpler, …”. I would prefer an other ordering of information there. It seems that the mentioned compilation error gave you motivation for the shown source code transformation. I suggest to move the concrete update suggestion behind it. > +virtual patch > +virtual report > +virtual org How do you think about to reduce a bit of code repetition? +virtual patch, report, org > In particular, I have conciously not removed the intermediate msg > variable; as I made the message longer I actually added one more of > these for the org mode section. I propose again to reconsider such an implementation detail once more so that unnecessary Python code could be avoided. The Linux coding style supports the usage of long message strings. https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/coding-style.rst?id=2db39a2f491a48ec740e0214a7dd584eefc2137d#n81 Can string literals be nicer than extra variables (because of questionable source code layout concerns)? Regards, Markus