* Re: [v3] Coccinelle: suggest replacing strncpy+truncation by strscpy
[not found] <1532047018-23754-1-git-send-email-asmadeus@codewreck.org>
@ 2018-07-20 9:40 ` SF Markus Elfring
0 siblings, 0 replies; 2+ messages in thread
From: SF Markus Elfring @ 2018-07-20 9:40 UTC (permalink / raw)
To: Dominique Martinet, kernel-janitors
Cc: cocci, linux-kernel, Gilles Muller, Julia Lawall, Masahiro Yamada,
Michal Marek, Nicolas Palix, Ville Syrjälä
> I didn't move all virtuals in a single line because none of the other
> kernel patch do it,
It can be occasionally useful to preserve another bit of coding tradition.
I dared to propose the reconsideration of such an implementation detail.
> and still do not see any advantage of moving the string to not use a variable
> so kept that as well.
I am curious if other software developers (besides me) would like to achieve
more source code reduction according to the principle “Don't repeat yourself”.
> This should hopefully be the last version :)
* Do any related development concerns need further safety checks for this
evolving source code transformation pattern?
* Julia Lawall has presented additional development ideas today.
https://lore.kernel.org/lkml/alpine.DEB.2.20.1807200759230.2349@hadrien/
https://lkml.org/lkml/2018/7/20/71
Regards,
Markus
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [v3] Coccinelle: suggest replacing strncpy+truncation by strscpy
[not found] <alpine.DEB.2.20.1807200745400.2349@hadrien>
@ 2018-07-20 11:00 ` SF Markus Elfring
0 siblings, 0 replies; 2+ messages in thread
From: SF Markus Elfring @ 2018-07-20 11:00 UTC (permalink / raw)
To: Julia Lawall, kernel-janitors
Cc: cocci, linux-kernel, Dominique Martinet, Gilles Muller,
Masahiro Yamada, Michal Marek, Nicolas Palix,
Ville Syrjälä
> The problem is that I don't know if the script is correct
Will the clarification of such a concern evolve into another interesting
software development adventure?
> - I'm not familiar with these string functions.
How are the chances to improve the understanding of affected programming
interfaces anyhow?
https://elixir.bootlin.com/linux/v4.18-rc5/source/lib/string.c#L154
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/lib/string.c?id(c20cc73b9cc4288c86c2a3fc62af4087de4b19#n154
Regards,
Markus
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-07-20 11:00 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1532047018-23754-1-git-send-email-asmadeus@codewreck.org>
2018-07-20 9:40 ` [v3] Coccinelle: suggest replacing strncpy+truncation by strscpy SF Markus Elfring
[not found] <alpine.DEB.2.20.1807200745400.2349@hadrien>
2018-07-20 11:00 ` SF Markus Elfring
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox