libconnect: lib/platform/sys_nt.c: minor refactoring and cleaning up of code