The is getting rather OT but what kind of exploit can you possibly have when we are talking about signing a tx offline (either it is going to be signed or it isn't)?
The reason you're signing a transaction offline is because you assume it's possible for an attacker to compromise your online computer. In that case you have to assume the attacker can alter the QR code that's being delivered to the offline computer, which means there's a non-zero possibility the attacker can compromise your offline computer as well.
Image processing libraries, like any other kind of software that processes arbitrary input, can fail in ways that allow arbitrary code execution. A few years ago it was possible to take over Windows computers if you could convince the user to load a web site containing a malicious JPEG image.
There are ways to reduce this risk by auditing code audits, fuzz testing, and other techniques but those don't completely eliminate the risk.