mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-21 16:23:34 +08:00
Strict sign conversions
This commit is contained in:
@@ -207,7 +207,7 @@ DataTypeSignature GlobalDataTypeRegistry::computeAggregateSignature(DataTypeKind
|
||||
const DataTypeDescriptor& desc = p->descriptor;
|
||||
const int dtid = desc.getID().get();
|
||||
|
||||
if (inout_id_mask[dtid])
|
||||
if (inout_id_mask[unsigned(dtid)])
|
||||
{
|
||||
if (signature_initialized)
|
||||
{
|
||||
@@ -224,7 +224,7 @@ DataTypeSignature GlobalDataTypeRegistry::computeAggregateSignature(DataTypeKind
|
||||
prev_dtid++;
|
||||
while (prev_dtid < dtid)
|
||||
{
|
||||
inout_id_mask[prev_dtid++] = false; // Erasing bits for missing types
|
||||
inout_id_mask[unsigned(prev_dtid++)] = false; // Erasing bits for missing types
|
||||
}
|
||||
UAVCAN_ASSERT(prev_dtid == dtid);
|
||||
|
||||
@@ -233,7 +233,7 @@ DataTypeSignature GlobalDataTypeRegistry::computeAggregateSignature(DataTypeKind
|
||||
prev_dtid++;
|
||||
while (prev_dtid <= DataTypeID::Max)
|
||||
{
|
||||
inout_id_mask[prev_dtid++] = false;
|
||||
inout_id_mask[unsigned(prev_dtid++)] = false;
|
||||
}
|
||||
|
||||
return signature;
|
||||
|
||||
@@ -172,7 +172,7 @@ int Scheduler::spin(MonotonicTime deadline)
|
||||
}
|
||||
|
||||
const MonotonicTime ts = deadline_scheduler_.pollAndGetMonotonicTime(getSystemClock());
|
||||
pollCleanup(ts, retval);
|
||||
pollCleanup(ts, unsigned(retval));
|
||||
if (ts >= deadline)
|
||||
{
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user