1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-12-01 09:24:10 +01:00

bitfields: bugfix for bugfix: forgot one line

This commit is contained in:
Corvus Corax 2012-05-17 00:25:30 +02:00
parent 8e790642a0
commit d2606e64e4

View File

@ -492,7 +492,7 @@ void UAVObjectField::clear()
switch (type)
{
case BITFIELD:
memset(&data[offset], 0, numBytesPerElement*((quint32)(numElements/8)));
memset(&data[offset], 0, numBytesPerElement*((quint32)(1+(numElements-1)/8)));
break;
default:
memset(&data[offset], 0, numBytesPerElement*numElements);