hostname: add win32 implementation

This patch adds an implementation for supporting local hostname querying
on Windows platforms.

Signed-off-by: Balazs Scheidler <bazsi@balabit.hu>