This was something I wasn't sure of. How do you know this for a fact?
But if the barcode contains control characters, it acts like a keyboard macro and will send them to the application. So if I embed a Ctrl-S in my hostile barcode, I can tell the software to save the record with data I supplied.
So far as attacks via UPC/EAN/IAN, they're not really possible as it only encodes digits, and only 13 of them.
¹ https://en.wikipedia.org/wiki/International_Article_Number_(...