mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-02-04 12:41:34 +00:00
cpukit/libfs/rfs: Address -Wsign-compare warnings
This warning occurs when comparing a signed variable to an unsigned one. This is frequently an int or ssize_t variable compared to a uint32_t or size_t. Sometimes the size_t is from a sizeof() use. This addresses sign comparison warnings in the RFS.
This commit is contained in:
committed by
Gedare Bloom
parent
785130d379
commit
dd4670e83d
@@ -443,7 +443,7 @@ rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
|
||||
if (!rtems_rfs_bitmap_match (*search_bits, RTEMS_RFS_BITMAP_ELEMENT_SET))
|
||||
{
|
||||
while ((search_offset >= 0)
|
||||
&& (search_offset < rtems_rfs_bitmap_element_bits ()))
|
||||
&& ((size_t) search_offset < rtems_rfs_bitmap_element_bits ()))
|
||||
{
|
||||
if (!rtems_rfs_bitmap_test (*search_bits, search_offset))
|
||||
{
|
||||
@@ -452,7 +452,7 @@ rtems_rfs_search_map_for_clear_bit (rtems_rfs_bitmap_control* control,
|
||||
* found. We may find none are spare if searching up from the seed.
|
||||
*/
|
||||
while ((map_offset >= 0)
|
||||
&& (map_offset < rtems_rfs_bitmap_element_bits ()))
|
||||
&& ((size_t) map_offset < rtems_rfs_bitmap_element_bits ()))
|
||||
{
|
||||
if (!rtems_rfs_bitmap_test (*map_bits, map_offset))
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user