summaryrefslogtreecommitdiff
path: root/src/core/perf_stats.cpp
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2018-10-13 08:12:00 -0400
committerLioncash <mathew1800@gmail.com>2018-10-13 08:24:18 -0400
commitef5639bfbbeb7d83bd66e3faf3e88e4aa1e05a6e (patch)
tree80c8f1dbccfb4dd33978e317d097befa8886ab74 /src/core/perf_stats.cpp
parent82ea1cf35a2b10bb7a2cfbaa0d9bac98fe5bb182 (diff)
key_manager: Don't assume file seeks and reads will always succeed
Given the filesystem should always be assumed to be volatile, we should check and bail out if a seek operation isn't successful. This'll prevent potentially writing/returning garbage data from the function in rare cases. This also allows removing a check to see if an offset is within the bounds of a file before perfoming a seek operation. If a seek is attempted beyond the end of a file, it will fail, so this essentially combines two checks into one in one place.
Diffstat (limited to 'src/core/perf_stats.cpp')
0 files changed, 0 insertions, 0 deletions