mirror of
https://github.com/espressif/esp-nimble.git
synced 2026-08-13 21:47:53 +00:00
porting: Fix redundant conditions
Both "blocks" and "block_size" are unsigned so they cannot be <0...
This commit is contained in:
@@ -70,7 +70,7 @@ os_mempool_init(struct os_mempool *mp, uint16_t blocks, uint32_t block_size,
|
||||
struct os_memblock *block_ptr;
|
||||
|
||||
/* Check for valid parameters */
|
||||
if (!mp || (blocks < 0) || (block_size <= 0)) {
|
||||
if (!mp || (block_size == 0)) {
|
||||
return OS_INVALID_PARM;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user