When creating code that will call move semantics versions of QImage::rgbSwapped() and QImage::mirrored(), it will break backwards compatibility between 5.2 and 5.3. The move semantics version of these methods are not documented at all.
Steps to reproduce:
- Run attached sample
- EXPECTED: No problems are detected
- ACTUAL: rgbSwapped() and mirrored() methods will access the temporary QImage buffers directly, which will cause program to later access memory that is already released.
This problem is most easily detected with Visual Studio, debug build. Also Valgrind will detect the invalid memory access.