diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2023-03-23 16:38:56 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2023-04-26 10:39:34 +0200 |
commit | 6979b03b0c9c72c786f06f3f3bb7680668d60983 (patch) | |
tree | a0defaa34bc4ce7d7fffba95237771e332d0319e /cpukit | |
parent | score: Avoid cyclic header file dependencies (diff) | |
download | rtems-6979b03b0c9c72c786f06f3f3bb7680668d60983.tar.bz2 |
score: Simplify _Objects_Is_api_valid()
Close #4863.
Diffstat (limited to 'cpukit')
-rw-r--r-- | cpukit/include/rtems/score/objectimpl.h | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/cpukit/include/rtems/score/objectimpl.h b/cpukit/include/rtems/score/objectimpl.h index c58957ccb5..a1a87b5ccb 100644 --- a/cpukit/include/rtems/score/objectimpl.h +++ b/cpukit/include/rtems/score/objectimpl.h @@ -542,9 +542,7 @@ static inline bool _Objects_Is_api_valid( uint32_t the_api ) { - if ( !the_api || the_api > OBJECTS_APIS_LAST ) - return false; - return true; + return ( 1 <= the_api && the_api <= OBJECTS_APIS_LAST ); } /** |