[CDRIVER-896] Error messages sometimes truncated at 63 chars Created: 30/Sep/15 Updated: 10/Aug/16 Resolved: 18/Apr/16 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | errors, libbson |
| Affects Version/s: | None |
| Fix Version/s: | 1.4.0 |
| Type: | Bug | Priority: | Minor - P4 |
| Reporter: | A. Jesse Jiryu Davis | Assignee: | A. Jesse Jiryu Davis |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
BSON_ERROR_BUFFER_SIZE is defined as 64, but it's used in a few places to format bson_error_t message strings, which can be 504 bytes (including nil). Set it to the proper length and use it in the bson_error_t declaration. There's a static check in bson-types.h to ensure the lengths add up correctly:
Review calls to bson_set_error and use the macro everywhere appropriate. |
| Comments |
| Comment by Githook User [ 18/Apr/16 ] |
|
Author: {u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}Message: |