Messages in this thread |  | | Date | Tue, 21 Aug 2018 16:13:10 +0100 | From | Tony Finch <> | Subject | Re: [PATCH] scripts: unifdef: fix stringop-truncation warning |
| |
Harshit Jain <harshitjain6751@gmail.com> wrote:
> /* modify this line */ > -static void Mpass (void) { strncpy(keyword, "if ", 4); Pelif(); } > +static void Mpass (void) { memcpy(keyword, "if ", 4); Pelif(); }
Yes, this is a good improvement, but you also need to update the comment to match the code.
Tony. -- f.anthony.n.finch <dot@dotat.at> http://dotat.at/ Wight, Portland, Plymouth: Westerly 3 or 4, occasionally 5 in north. Slight, occasionally moderate. Drizzle, fog banks. Moderate, occasionally very poor.
|  |