Skip to content

[core] Change the date/time API to a more race-unfriendly one#737

Open
pgimeno4d wants to merge 1 commit intoEnet4:masterfrom
pgimeno4d:date-time-now-api
Open

[core] Change the date/time API to a more race-unfriendly one#737
pgimeno4d wants to merge 1 commit intoEnet4:masterfrom
pgimeno4d:date-time-now-api

Conversation

@pgimeno4d
Copy link
Contributor

@pgimeno4d pgimeno4d commented Feb 9, 2026

Fix #691 with a different approach: DicomDateTime now implements two methods separate_date_time_now_local and separate_date_time_now_utc, both of which return both a DicomDate and a DicomTime at the same time, based on the same timestamp. Also, DicomDateTime::now_local() and DicomDateTime::now_utc() are no longer based on separate calls to obtain a date and a time, which was open to races.

Add some docs while on it.

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.

Could use DicomDateTime::now

1 participant

Comments