mazen Adel commented on a discussion on testsuites/psxtests/psxtimes01/init.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/670#note_129312 > rtems_test_assert( end_tm.tms_cstime == 0 ); > +} > + > +static void test_timespec_functions( void ) > +{ > + struct timespec start_ts; > + struct timespec end_ts; > + struct timespec clock_ts; > + int result; > + int interval = 5; > + > + puts( "\n*** Testing timespec_get() functions ***" ); > + > + puts( "timespec_get( NULL, TIME_UTC ) -- EINVAL" ); > + result = timespec_get( NULL, TIME_UTC ); > + rtems_test_assert( result == 0 ); Nothing about the errors was written in either [Posix Issue 8 docs ](https://pubs.opengroup.org/onlinepubs/9799919799/functions/timespec_get.html)or [C11 docs](https://en.cppreference.com/w/c/chrono/timespec_get), [Linux](https://man7.org/linux/man-pages/man3/timespec_get.3.html) however said not to depend on a return value. So we can either set `errno = EINVAL` or not which depends on your opinion. If not I should change the comment because it is misleading. -- View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/670#note_129312 You're receiving this email because of your account on gitlab.rtems.org.
_______________________________________________ bugs mailing list [email protected] http://lists.rtems.org/mailman/listinfo/bugs
