mirror of
https://github.com/overte-org/overte.git
synced 2025-04-22 09:33:36 +02:00
Merge pull request #1186 from ZappoMan/bugfixes
fixed warning and logic problem
This commit is contained in:
commit
ead307216f
2 changed files with 2 additions and 2 deletions
|
@ -50,7 +50,7 @@ void VoxelServerPacketProcessor::processPacket(sockaddr& senderAddress, unsigned
|
|||
unsigned char* voxelData = (unsigned char*)&packetData[atByte];
|
||||
while (atByte < packetLength) {
|
||||
int maxSize = packetLength - atByte;
|
||||
unsigned char octets = numberOfThreeBitSectionsInCode(voxelData, maxSize);
|
||||
int octets = numberOfThreeBitSectionsInCode(voxelData, maxSize);
|
||||
|
||||
if (octets == OVERFLOWED_OCTCODE_BUFFER) {
|
||||
printf("WARNING! Got voxel edit record that would overflow buffer in numberOfThreeBitSectionsInCode(), ");
|
||||
|
|
|
@ -582,7 +582,7 @@ void VoxelTree::processRemoveVoxelBitstream(unsigned char * bitstream, int buffe
|
|||
unsigned char* voxelCode = (unsigned char*)&bitstream[atByte];
|
||||
while (atByte < bufferSizeBytes) {
|
||||
int maxSize = bufferSizeBytes - atByte;
|
||||
unsigned char codeLength = numberOfThreeBitSectionsInCode(voxelCode, maxSize);
|
||||
int codeLength = numberOfThreeBitSectionsInCode(voxelCode, maxSize);
|
||||
|
||||
if (codeLength == OVERFLOWED_OCTCODE_BUFFER) {
|
||||
printf("WARNING! Got remove voxel bitstream that would overflow buffer in numberOfThreeBitSectionsInCode(), ");
|
||||
|
|
Loading…
Reference in a new issue