Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Use time_t instead of long for time#70

Merged
olebole merged 1 commit into
iraf-community:mainfrom
olebole:time_t
Aug 26, 2024
Merged

Use time_t instead of long for time#70
olebole merged 1 commit into
iraf-community:mainfrom
olebole:time_t

Conversation

@olebole
Copy link
Copy Markdown
Member

@olebole olebole commented Aug 20, 2024

There are few places where time is used in x11iraf; this patch makes sure that time_t is used here instead of long. This makes x11iraf compilable with newer Linux distributions (which made the time_t transition to ensure working after 2038).

Also, we always use time(NULL);, not time(0); (argument is a pointer, not a number) or time((long *)NULL); (NULL pointers are valid for all pointer types without cast).

@olebole olebole merged commit 92133fd into iraf-community:main Aug 26, 2024
@olebole olebole deleted the time_t branch August 26, 2024 09:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant