fixed issue with special chars

use [string lengthOfBytesUsingEncoding:NSUTF8StringEncoding] instead of sizeof(char) * (string.length + 1) because it calculates the length wrong if you have sepcial characters like äöü in your string