add utfnlen declaration chan.c calls it