Fixed up a compiler warning and added a nice general purpose codepoint to utf-8 conversion function.