[SERVER-38445] Date_t and Duration addition can overflow Created: 06/Dec/18 Updated: 29/Oct/23 Resolved: 07/Dec/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Internal Code |
| Affects Version/s: | None |
| Fix Version/s: | 4.0.6, 4.1.7 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Matthew Saltz (Inactive) | Assignee: | Matthew Saltz (Inactive) |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Backwards Compatibility: | Fully Compatible | ||||
| Backport Requested: |
v4.0
|
||||
| Sprint: | Sharding 2018-12-17 | ||||
| Participants: | |||||
| Description |
|
The following code leads to a silent overflow:
This should throw an exception instead. |
| Comments |
| Comment by Githook User [ 11/Jan/19 ] |
|
Author: {'username': 'saltzm', 'email': 'matthew.saltz@mongodb.com', 'name': 'Matthew Saltz'}Message: (cherry picked from commit d899a205ef66d916b071dd42fbb619775561a523) |
| Comment by Githook User [ 07/Dec/18 ] |
|
Author: {'name': 'Matthew Saltz', 'email': 'matthew.saltz@mongodb.com', 'username': 'saltzm'}Message: |