Re: [PATCH weston] rdp: Check for non-numeric value in RDP_FD env var

2016-07-11 Thread Bryce Harrington
On Fri, Jul 08, 2016 at 08:11:26PM -0700, Yong Bakos wrote: > On Jul 8, 2016, at 6:54 PM, Bryce Harrington wrote: > > > > strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where > > no digits were read from the string, and return 0. Running with > > RDP_FD=foo would thus result

Re: [PATCH weston] rdp: Check for non-numeric value in RDP_FD env var

2016-07-08 Thread Yong Bakos
On Jul 8, 2016, at 6:54 PM, Bryce Harrington wrote: > > strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where > no digits were read from the string, and return 0. Running with > RDP_FD=foo would thus result in fd=0 being specified to > freerdp_peer_new(), which is unlikely to

[PATCH weston] rdp: Check for non-numeric value in RDP_FD env var

2016-07-08 Thread Bryce Harrington
strtoul(nptr, endptr, ...) will set *endptr to nptr in the case of where no digits were read from the string, and return 0. Running with RDP_FD=foo would thus result in fd=0 being specified to freerdp_peer_new(), which is unlikely to be the user's intent. Signed-off-by: Bryce Harrington --- lib