Fix barcode encoding.