Changeset 9a5cbef0 in rtems
- Timestamp:
- 09/05/96 20:29:07 (27 years ago)
- Branches:
- 4.10, 4.11, 4.8, 4.9, 5, master
- Children:
- 7e230f10
- Parents:
- f254b93f
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
c/src/exec/posix/src/time.c
rf254b93f r9a5cbef0 246 246 ) 247 247 { 248 Watchdog_Interval ticks; 248 Watchdog_Interval ticks; 249 struct timespec *the_rqtp; 249 250 250 251 if ( !rqtp ) 251 252 set_errno_and_return_minus_one( EINVAL ); 253 254 the_rqtp = (struct timespec *)rqtp; 252 255 253 256 /* … … 258 261 */ 259 262 260 if ( rqtp->tv_sec < 0 || rqtp->tv_nsec < 0 ) 263 if ( the_rqtp->tv_sec < 0 ) 264 the_rqtp->tv_sec = 0; 265 266 if ( /* the_rqtp->tv_sec < 0 || */ the_rqtp->tv_nsec < 0 ) 261 267 set_errno_and_return_minus_one( EAGAIN ); 262 268 263 if ( rqtp->tv_nsec >= TOD_NANOSECONDS_PER_SECOND )269 if ( the_rqtp->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) 264 270 set_errno_and_return_minus_one( EINVAL ); 265 271 266 ticks = _POSIX_Timespec_to_interval( rqtp );272 ticks = _POSIX_Timespec_to_interval( the_rqtp ); 267 273 268 274 /* -
cpukit/posix/src/time.c
rf254b93f r9a5cbef0 246 246 ) 247 247 { 248 Watchdog_Interval ticks; 248 Watchdog_Interval ticks; 249 struct timespec *the_rqtp; 249 250 250 251 if ( !rqtp ) 251 252 set_errno_and_return_minus_one( EINVAL ); 253 254 the_rqtp = (struct timespec *)rqtp; 252 255 253 256 /* … … 258 261 */ 259 262 260 if ( rqtp->tv_sec < 0 || rqtp->tv_nsec < 0 ) 263 if ( the_rqtp->tv_sec < 0 ) 264 the_rqtp->tv_sec = 0; 265 266 if ( /* the_rqtp->tv_sec < 0 || */ the_rqtp->tv_nsec < 0 ) 261 267 set_errno_and_return_minus_one( EAGAIN ); 262 268 263 if ( rqtp->tv_nsec >= TOD_NANOSECONDS_PER_SECOND )269 if ( the_rqtp->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) 264 270 set_errno_and_return_minus_one( EINVAL ); 265 271 266 ticks = _POSIX_Timespec_to_interval( rqtp );272 ticks = _POSIX_Timespec_to_interval( the_rqtp ); 267 273 268 274 /*
Note: See TracChangeset
for help on using the changeset viewer.