Re: [PATCH] cifs: remove misleading strncpy: each name has length < 16

2012-08-20 Thread Jim Meyering
Jim Meyering wrote: > From: Jim Meyering > > Each of the protocols[i].name strings (statically declared above) > has length less than 16, so this use of strncpy is misleading: > strncpy(pSMB->DialectsArray+count, protocols[i].name, 16); > Besides, if a new name were added with length N >= 16, t

Re: [PATCH] cifs: remove misleading strncpy: each name has length < 16

2012-08-20 Thread Jim Meyering
Bastien ROUCARIES wrote: > Le 20 août 2012 19:29, "Jim Meyering" a écrit : >> >> From: Jim Meyering >> >> Each of the protocols[i].name strings (statically declared above) >> has length less than 16, so this use of strncpy is misleading: >>   strncpy(pSMB->DialectsArray+count, protocols[i].name,

[PATCH] cifs: remove misleading strncpy: each name has length < 16

2012-08-20 Thread Jim Meyering
From: Jim Meyering Each of the protocols[i].name strings (statically declared above) has length less than 16, so this use of strncpy is misleading: strncpy(pSMB->DialectsArray+count, protocols[i].name, 16); Besides, if a new name were added with length N >= 16, the existing strncpy-using code w