forked from maidsafe/lru_time_cache
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bugfix: fix edge cases related to time atomicity
These changes aim to make it so that calls to the public API operate over the cache using a single Instant of time rather than calling Instant::now() at several unique points in time during the synchronous execution of the function. The former execution model lead to potential bugs, notably in functions like entry() as brought up in maidsafe#122, especially on targets with less processing power or under heavy load. This also reduces the number of system calls that need to be made which may improve performance for some use cases. Signed-off-by: Paul Osborne <[email protected]>
- Loading branch information
Showing
1 changed file
with
75 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters