[CDRIVER-3489] Fix and deduplicate safe isspace checks Created: 16/Jan/20 Updated: 28/Oct/23 Resolved: 30/Jan/20 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 1.16.1 |
| Type: | Improvement | Priority: | Trivial - P5 |
| Reporter: | Kevin Albertson | Assignee: | Kevin Albertson |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Description |
|
There are checks in libbson, once in libmongoc, and once in the common library. We should probably refactor this into one function, perhaps named isspace_safe either in bson-string.h or somewhere in common library. Additionally, the check in common-b64.c checks with an unsigned char, making the comparison of -1 redundant and triggering an autological warning. |
| Comments |
| Comment by Githook User [ 30/Jan/20 ] |
|
Author: {'username': 'kevinAlbs', 'name': 'Kevin Albertson', 'email': 'kevin.albertson@mongodb.com'}Message: |
| Comment by Githook User [ 30/Jan/20 ] |
|
Author: {'username': 'kevinAlbs', 'name': 'Kevin Albertson', 'email': 'kevin.albertson@mongodb.com'}Message: |