Skip to content
This repository has been archived by the owner on Sep 1, 2022. It is now read-only.

check max/min values for ms, s, min when constructing TimeDuration #382

Merged
merged 2 commits into from Jun 1, 2020

Conversation

jadamcrain
Copy link
Member

Fix for #381

std::chrono::<milliseconds, seconds, etc> can mult overflow b/c of ratio conversions when
storing in std::chrono::steady_clock duration.

@codecov
Copy link

codecov bot commented Jun 1, 2020

Codecov Report

Merging #382 into develop will increase coverage by 0.08%.
The diff coverage is 100.00%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #382      +/-   ##
===========================================
+ Coverage    51.67%   51.75%   +0.08%     
===========================================
  Files          456      456              
  Lines        13598    13602       +4     
===========================================
+ Hits          7027     7040      +13     
+ Misses        6571     6562       -9     
Impacted Files Coverage Δ
cpp/lib/src/util/TimeDuration.cpp 87.50% <100.00%> (+12.50%) ⬆️
cpp/lib/src/link/LinkContext.cpp 90.16% <0.00%> (+0.54%) ⬆️
cpp/lib/src/channel/IOHandler.cpp 80.15% <0.00%> (+3.05%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 315546b...3a29024. Read the comment docs.

@jadamcrain jadamcrain merged commit 279788e into develop Jun 1, 2020
@jadamcrain jadamcrain deleted the bug/prevent-duration-overflow branch June 1, 2020 21:05
@jadamcrain jadamcrain changed the title check maximum values for ms, s, min when constructing TimeDuration check max/min values for ms, s, min when constructing TimeDuration Jun 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant