If you use QDataStream here you can avoid writing your custom PutNum().
eg.
```c++
QDataStream data_stream(stream);
data_stream << kkWavHeaderRiffMarker;
data_stream << i_bytecount + 44 - 8;  // You might need to do something like static_cast<qint32>(i_bytecount + 44 - *) to make sure it's a 4 byte int.
```