Fix build with gcc 4.8

Authored by wbauer on Nov 8 2017, 10:55 AM.



When building master with gcc 4.8, the build fails with errors like this:

error: no matching function for call to 'MediaPlayer2Player::connect(QPointer<PlayerManager>&, void (PlayerManager::*)(const FileHandle&), MediaPlayer2Player* const, void (MediaPlayer2Player::*)()const)'

See also

This patch fixes it.

The fix is similar to fixes in other applications, e.g.

Test Plan

Compiles fine now with gcc 4.8 and also newer versions.

Diff Detail

R344 Juk
Automatic diff as part of commit; lint not applicable.
Automatic diff as part of commit; unit tests not applicable.
wbauer created this revision.Nov 8 2017, 10:55 AM
mpyne accepted this revision.Nov 9 2017, 12:13 AM

This is fine to commit, but please add a comment to the effect of //FIXME: Workaround for GCC 4.8, remove .data() in 2019. I can confirm this works fine with more recent GCCs (it seems this is a compiler bug as the QTBUG commentary states). I'm not sure which GCC compiler is the first to have this bug fixed but I can't imagine that I'd wait past 2019 either way.

This revision is now accepted and ready to land.Nov 9 2017, 12:13 AM
wbauer added a comment.Nov 9 2017, 1:25 PM

OK, I'll add that comment when I commit it.

This revision was automatically updated to reflect the committed changes.