Skip to content
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

Make localtime and localtime_r aware of system timezone #41

Merged
merged 3 commits into from
Feb 27, 2019
Merged

Make localtime and localtime_r aware of system timezone #41

merged 3 commits into from
Feb 27, 2019

Conversation

althonos
Copy link
Contributor

Hi everyone !

Just a quick PR to make localtime_r (and subsequently localtime) aware of the user-specified timezone. Currently, localtime and gmtime will always return the same value (found after bissecting libretro/RetroArch#7632).

I hope it's the right way to do things, I've been working with the SDK a bit but this is my first time messing with newlib's code.

@althonos
Copy link
Contributor Author

NB: This has been tested on a UTC+1 PS Vita running w/ Henkaku 3.60.

newlib/libc/sys/vita/lcltime_r.c Outdated Show resolved Hide resolved
newlib/libc/sys/vita/lcltime_r.c Outdated Show resolved Hide resolved
@ofry
Copy link

ofry commented Feb 27, 2019

@althonos Could you fix these cosmetic issues?

@ofry
Copy link

ofry commented Feb 27, 2019

@d3m3vilurr Could you review this PR again?

@d3m3vilurr d3m3vilurr merged commit cc721af into vitasdk:vita Feb 27, 2019
@d3m3vilurr
Copy link
Contributor

@althonos @ofry Thanks!

frangarcj pushed a commit that referenced this pull request Jul 23, 2021
* Add `vita/lcltime_r.c` to provide localtime_r using SceRtc functions

* Use hardtabs instead of spaces in `sys/vita/lcltime_r.c`

* Use `rid` as `errno` in `lcltime_r.c`
frangarcj pushed a commit that referenced this pull request Aug 1, 2021
* Add `vita/lcltime_r.c` to provide localtime_r using SceRtc functions

* Use hardtabs instead of spaces in `sys/vita/lcltime_r.c`

* Use `rid` as `errno` in `lcltime_r.c`
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.

3 participants