Skip to content

Conversation

@Rajin9601
Copy link

to fix #61
related to #61 (comment)

Using the difference between deviceCurrentTime and deviceElapsedTime can trigger false negative on isFromSameBoot.
To avoid this false-negative case, this PR uses boot count from Settings.Global.BOOT_COUNT.

For case when bootCount is not available to the device (e.g. without Android or android sdk below 24) this PR uses bootCount only when it's available. When there is no bootCount, it uses the same algorithm that has been used before this PR.

@jh0719
Copy link

jh0719 commented Feb 11, 2022

This is a great find! I never knew this setting existed. Curious to know how well this might be working with testing.

@glureau
Copy link

glureau commented Oct 1, 2024

still relevant?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

getCurrentTimeMs() return the wrong date time everytime I manually change the device clock

3 participants