Skip to content

fix: QString from QByteArray changes with Qt6 - #43

Open
letsfindaway wants to merge 1 commit into
openSUSE:masterfrom
letsfindaway:fix-qstring-from-qbytearray
Open

fix: QString from QByteArray changes with Qt6#43
letsfindaway wants to merge 1 commit into
openSUSE:masterfrom
letsfindaway:fix-qstring-from-qbytearray

Conversation

@letsfindaway

Copy link
Copy Markdown
Contributor

This bug was detected by Edgar Aichinger while building the package on OBS for TW.

  • in Qt6, the behavior of the QString(QByteArray) constructor was changed, see https://doc.qt.io/qt-6/qstring.html#QString-4
  • this causes a NULL byte at the end of a QByteArray to be included in the resulting QString
  • this again causes problems when the result is used to construct further DBus calls
  • remove NULL bytes from QByteArray to fix this

- in Qt6, the behavior of the QString(QByteArray) constructor
  was changed, see https://doc.qt.io/qt-6/qstring.html#QString-4
- this causes a NULL byte at the end of a QByteArray to be included
  in the resulting QString
- this again causes problems when the result is used to construct
  further DBus calls
- remove NULL bytes from QByteArray to fix this
@letsfindaway

Copy link
Copy Markdown
Contributor Author

Any comments to this fix? Without it imagewriter does not work with Qt 6.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant