Fix possibility of buffer overflow and add support for port numbers greater than 9.

git-svn-id: svn+ssh://svn.code.sf.net/p/winlirc/code/trunk@229 92c2518b-485e-4ca2-9c37-138eef3f838b