diff options
author | Ryan Harrison <rharrison@chromium.org> | 2017-09-13 11:16:32 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-09-13 15:42:13 +0000 |
commit | 06c6855258bf25246c46a1f628b8a8a8185029a7 (patch) | |
tree | 7db9bd2cae8672a06834105542cef5c70bc9db08 /AUTHORS | |
parent | f2ca50ffa2d26a6c023add24e92adbe6b28bfcc9 (diff) | |
download | pdfium-06c6855258bf25246c46a1f628b8a8a8185029a7.tar.xz |
Rewrite IsHyphen using string operations
The existing code did end of range checks by making sure that the
value was never less then 0. This isn't correct when using an unsigned
type, since 0 - 1 will wrap around to the max possible value, and
thus still be less then 0. Additionally the existing code was hard to
follow due to the complexity of some of the low level operations being
performed.
It has been rewritten using higher level string operations to make it
clearer and correct.
BUG=chromium:763256
Change-Id: Ib8bf5ca0e29e73724c4a1c4781362e8a8fc30149
Reviewed-on: https://pdfium-review.googlesource.com/13690
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'AUTHORS')
0 files changed, 0 insertions, 0 deletions