mirror of
https://github.com/lubosz/overte.git
synced 2025-04-24 00:13:53 +02:00
fix windows build errors and warnings
This commit is contained in:
parent
7d5366a1b8
commit
a05e07460f
4 changed files with 5 additions and 4 deletions
|
@ -481,7 +481,7 @@ void Audio::addReceivedAudioToBuffer(const QByteArray& audioByteArray) {
|
|||
|
||||
// copy the samples we'll resample from the ring buffer - this also
|
||||
// pushes the read pointer of the ring buffer forwards
|
||||
int16_t ringBufferSamples[numNetworkOutputSamples];
|
||||
int16_t* ringBufferSamples= new int16_t[numNetworkOutputSamples];
|
||||
_ringBuffer.readSamples(ringBufferSamples, numNetworkOutputSamples);
|
||||
|
||||
// add the next numNetworkOutputSamples from each QByteArray
|
||||
|
@ -502,6 +502,7 @@ void Audio::addReceivedAudioToBuffer(const QByteArray& audioByteArray) {
|
|||
Q_ARG(QByteArray, QByteArray((char*) ringBufferSamples, numNetworkOutputSamples)),
|
||||
Q_ARG(bool, true), Q_ARG(bool, false));
|
||||
}
|
||||
delete[] ringBufferSamples;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -138,7 +138,7 @@ void DatagramSequencer::receivedDatagram(const QByteArray& datagram) {
|
|||
}
|
||||
|
||||
// read and dispatch the high-priority messages
|
||||
quint32 highPriorityMessageCount;
|
||||
int highPriorityMessageCount;
|
||||
_incomingPacketStream >> highPriorityMessageCount;
|
||||
int newHighPriorityMessages = highPriorityMessageCount - _receivedHighPriorityMessages;
|
||||
for (int i = 0; i < highPriorityMessageCount; i++) {
|
||||
|
|
|
@ -337,7 +337,7 @@ void NodeList::processSTUNResponse(const QByteArray& packet) {
|
|||
|
||||
const uint32_t RFC_5389_MAGIC_COOKIE_NETWORK_ORDER = htonl(RFC_5389_MAGIC_COOKIE);
|
||||
|
||||
size_t attributeStartIndex = NUM_BYTES_STUN_HEADER;
|
||||
int attributeStartIndex = NUM_BYTES_STUN_HEADER;
|
||||
|
||||
if (memcmp(packet.data() + NUM_BYTES_MESSAGE_TYPE_AND_LENGTH,
|
||||
&RFC_5389_MAGIC_COOKIE_NETWORK_ORDER,
|
||||
|
|
|
@ -37,7 +37,7 @@ int packArithmeticallyCodedValue(int value, char* destination) {
|
|||
return 1;
|
||||
} else {
|
||||
// pack 255 and then recursively pack on
|
||||
destination[0] = 255;
|
||||
((unsigned char*)destination)[0] = 255;
|
||||
return 1 + packArithmeticallyCodedValue(value - 255, destination + 1);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue