bugfix for UTF input