Re: [PATCH v3] staging: android: Replace strcpy with strlcpy

2017-03-12 Thread Greg KH
On Sun, Mar 12, 2017 at 08:25:28PM +0530, SIMRAN SINGHAL wrote: > On Sun, Mar 12, 2017 at 7:04 PM, Greg KH wrote: > > On Sun, Mar 12, 2017 at 03:32:44AM +0530, simran singhal wrote: > >> Replace strcpy with strlcpy as strcpy does not check for buffer > >> overflow. > > > > Can there be a buffer ov

Re: [PATCH v3] staging: android: Replace strcpy with strlcpy

2017-03-12 Thread SIMRAN SINGHAL
On Sun, Mar 12, 2017 at 7:04 PM, Greg KH wrote: > On Sun, Mar 12, 2017 at 03:32:44AM +0530, simran singhal wrote: >> Replace strcpy with strlcpy as strcpy does not check for buffer >> overflow. > > Can there be a buffer overflow here? If not, then strcpy is just fine > to use. Do you see a poten

Re: [PATCH v3] staging: android: Replace strcpy with strlcpy

2017-03-12 Thread Greg KH
On Sun, Mar 12, 2017 at 03:32:44AM +0530, simran singhal wrote: > Replace strcpy with strlcpy as strcpy does not check for buffer > overflow. Can there be a buffer overflow here? If not, then strcpy is just fine to use. Do you see a potential code path here that actually is a problem using this?

[PATCH v3] staging: android: Replace strcpy with strlcpy

2017-03-11 Thread simran singhal
Replace strcpy with strlcpy as strcpy does not check for buffer overflow. This is found using Flawfinder. Signed-off-by: simran singhal --- v3: -Correcting the place of the parenthesis and sign drivers/staging/android/ashmem.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff