skupperproject / skupper-router

An application-layer router for Skupper networks
https://skupper.io
Apache License 2.0
14 stars 18 forks source link

Coverity issue: Checking if unsigned number is >= 0 #1536

Closed ganeshmurthy closed 2 weeks ago

ganeshmurthy commented 3 weeks ago

amqp.c

123    if (*endptr == '\0') {

CID 379188: (#1 of 1): Unsigned compared against 0 (NO_EFFECT)
unsigned_compare: This greater-than-or-equal-to-zero comparison of an unsigned value is always true. n >= 0UL.
124        if (!errno && n >= 0 && n <= 0xFFFF)
125            return n;
126        else
127            return -1;
128    }