summaryrefslogtreecommitdiffstats
path: root/contrib/diff/lib/unlocked-io.h
diff options
context:
space:
mode:
authorngie <ngie@FreeBSD.org>2016-06-08 17:32:41 +0000
committerngie <ngie@FreeBSD.org>2016-06-08 17:32:41 +0000
commitf3d2358a821eb701f0b18e11bb617d495950dc3b (patch)
treeb1dd431b8ac75c99d0d5a4d36ce5d68a9c8672cf /contrib/diff/lib/unlocked-io.h
parentd458a9c36b88dabc0b9567d8b60e86e34698be7f (diff)
downloadFreeBSD-src-f3d2358a821eb701f0b18e11bb617d495950dc3b.zip
FreeBSD-src-f3d2358a821eb701f0b18e11bb617d495950dc3b.tar.gz
MFC r299778:
Use a consistent errno save/restore pattern before running strtoul - Save errno - Set errno to 0 - Call strtoul - Test errno (optional, but many calls to strtoul did this afterwards) Some of the code was setting errno = 0 after calling strtoul, not setting errno = 0, or setting errno to saved_errno after the call, but before the test. These all have unwanted behavioral side-effects, depending on the initial value of errno and whether or not the input to strtoul was correct or incorrect.
Diffstat (limited to 'contrib/diff/lib/unlocked-io.h')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud