diff options
Diffstat (limited to 'cpukit/libcsupport/src/ftruncate.c')
-rw-r--r-- | cpukit/libcsupport/src/ftruncate.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/cpukit/libcsupport/src/ftruncate.c b/cpukit/libcsupport/src/ftruncate.c index 64c2dc0045..401510b2ff 100644 --- a/cpukit/libcsupport/src/ftruncate.c +++ b/cpukit/libcsupport/src/ftruncate.c @@ -29,10 +29,7 @@ int ftruncate( int fd, off_t length ) if ( length >= 0 ) { rtems_libio_t *iop; - rtems_libio_check_fd( fd ); - iop = rtems_libio_iop( fd ); - rtems_libio_check_is_open( iop ); - rtems_libio_check_permissions( iop, LIBIO_FLAGS_WRITE, EINVAL ); + LIBIO_GET_IOP_WITH_ACCESS( fd, iop, LIBIO_FLAGS_WRITE, EINVAL ); rv = (*iop->pathinfo.handlers->ftruncate_h)( iop, length ); } else { |