Skip to content

Replace "gmtime()" with its thread-safe version, "gmtime_r()" #51

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 9, 2020

Conversation

onelife
Copy link
Contributor

@onelife onelife commented Jul 16, 2019

"gmtime()" doesn't work when together with RTOS library, e.g. RT-Thread.

@drewfish
Copy link

drewfish commented Dec 2, 2020

I did some test compiles before and after this change. (Both done using platformio for Adafruit Feather M0.) In both cases the elf binary has both the gmtime and gmtime_r symbols, so somewhere in the Arduino framework both are already being used.

@per1234 per1234 added the type: enhancement Proposed improvement label Dec 2, 2020
Copy link
Contributor

@aentinger aentinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍 Thank you @onelife 🚀

@aentinger aentinger merged commit 5a7245f into arduino-libraries:master Dec 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement Proposed improvement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants