Re: [PATCH 2/2] libc/include/time.h: Added protoype for timespec_get() to time.h
Joel Sherrill <[email protected]>
| Newsgroups | gmane.comp.lib.newlib |
|---|---|
| Message-ID | <CAF9ehCUFmYj5EbprCK3RAzNeS=B47nvzhNxD3GKRJTzBR8PFFw@mail.gmail.com> |
Did you generate the patch with git format-patch? It doesn't look like it has a proper commit message. On Sun, May 11, 2025, 1:45 PM mez3n <[email protected]> wrote: > From: Mazen Adel Elmessady <[email protected]> > > Hi, > > Following up on my previous patch, I am submitting an update to the Newlib > headers by adding the prototype for `timespec_get()` in `time.h`. This > function is part of POSIX Issue 8 and is needed for RTEMS to improve > compliance with POSIX standards. > > This patch prepares for the implementation of `timespec_get()` in a future > update. > > Your feedback is appreciated. > > Best regards, > Mazen > <[email protected]> > --- > newlib/libc/include/time.h | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/newlib/libc/include/time.h b/newlib/libc/include/time.h > index ab3491341..33cf40049 100644 > --- a/newlib/libc/include/time.h > +++ b/newlib/libc/include/time.h > @@ -57,6 +57,9 @@ clock_t clock (void); > double difftime (time_t _time2, time_t _time1); > time_t mktime (struct tm *_timeptr); > time_t time (time_t *_timer); > +#if __STDC_VERSION__ >= 201112L > +int timespec_get(struct timespec *ts, int base); > +#endif > #ifndef _REENT_ONLY > char *asctime (const struct tm *_tblock); > char *ctime (const time_t *_time); > -- > 2.45.2 > >