slcanpty.c Remove one Bug
PATCH 1/1 slcanpty.c Remove one Bug
It is an error to overwrite nbytes at this point.
LG Ulrich
Signed-off-by ulrich escher<[email protected]>
--- slcanpty.c | 4 +++----- 1 file changed, 2 insertions(+), 2 deletions(-)
slcanpty.c +2 -2
@@ -281,8 +279,8 @@ rx_restart: ptr--; } - nbytes =write (socket, &frame,sizeof (frame)); -if (nbytes !=sizeof (frame)) { + tmp =write (socket, &frame,sizeof (frame)); +if (tmp !=sizeof (frame)) {perror ("write socket" );return 1 ; }
Marc Kleine-Budde
maintainerQuoted 2 lines · Ulrich Escher
It is an error to overwrite nbytes at this point.
LG Ulrich
Can you make the patch description a bit more verbose. With this patch alone it's impossible to see what's the nbytes is used for and what is the bug here.
Marc
Signature · 4 lines
Pengutronix e.K. | Marc Kleine-Budde | Industrial Linux Solutions | Phone: +49-231-2826-924 | Vertretung West/Dortmund | Fax: +49-5121-206917-5555 | Amtsgericht Hildesheim, HRA 2686 | http://www.pengutronix.de |