QByteArray can not support unsigned char?
I want read binary file and load data to unsigned char array. My code is:
Functions from QFile and QByteArray support only signed char not unsigned char. I can not understand reason for using signed char because for me byte=unsigned char.
Is there any possibility to read unsigned char from file? Of course I can convert every signed char to unsigned char but mayby exsist easier way for this problem?
Re: QByteArray can not support unsigned char?
Re: QByteArray can not support unsigned char?
QByteArray doesn't specify either signed or unsigned, check the header file. Therefore you can define it as either signed or unsigned depending on your requirements.
This is not a Qt issue, it's covered in the introduction to GCC.