diff options
author | Jennifer Averett <Jennifer.Averett@OARcorp.com> | 2008-01-18 16:31:57 +0000 |
---|---|---|
committer | Jennifer Averett <Jennifer.Averett@OARcorp.com> | 2008-01-18 16:31:57 +0000 |
commit | c3925dbe923bf0944235bc2c4556955f35b0dc91 (patch) | |
tree | cebd73d709e9f2c152f42d14362923dded35f0ef /cpukit/posix/src/mqueueclose.c | |
parent | 2008-01-18 David Erickson <David.Erickson@drdc-rddc.gc.ca> (diff) | |
download | rtems-c3925dbe923bf0944235bc2c4556955f35b0dc91.tar.bz2 |
2008-01-18 Jennifer Averett <jennifer.averett@OARcorp.com>
* posix/include/rtems/posix/timer.h, posix/src/cleanuppop.c,
posix/src/cleanuppush.c, posix/src/mqueueclose.c,
posix/src/timergettime.c, posix/src/timersettime.c,
score/include/rtems/score/timespec.h:
Diffstat (limited to 'cpukit/posix/src/mqueueclose.c')
-rw-r--r-- | cpukit/posix/src/mqueueclose.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/cpukit/posix/src/mqueueclose.c b/cpukit/posix/src/mqueueclose.c index e95118b2e0..35b4dc3ec1 100644 --- a/cpukit/posix/src/mqueueclose.c +++ b/cpukit/posix/src/mqueueclose.c @@ -11,7 +11,7 @@ * This code ignores the O_RDONLY/O_WRONLY/O_RDWR flag at open * time. * - * COPYRIGHT (c) 1989-2007. + * COPYRIGHT (c) 1989-2008. * On-Line Applications Research Corporation (OAR). * * The license and distribution terms for this file may be @@ -53,10 +53,9 @@ int mq_close( Objects_Locations location; the_mq_fd = _POSIX_Message_queue_Get_fd( mqdes, &location ); - switch ( location ) { - - case OBJECTS_LOCAL: - /* + if ( location == OBJECTS_LOCAL ) { + /* OBJECTS_LOCAL: + * * First update the actual message queue to reflect this descriptor * being disassociated. This may result in the queue being really * deleted. @@ -76,13 +75,11 @@ int mq_close( _Thread_Enable_dispatch(); return 0; + } -#if defined(RTEMS_MULTIPROCESSING) - case OBJECTS_REMOTE: -#endif - case OBJECTS_ERROR: - break; - } - - rtems_set_errno_and_return_minus_one( EBADF ); + /* + * OBJECTS_REMOTE: + * OBJECTS_ERROR: + */ + rtems_set_errno_and_return_minus_one( EBADF ); } |