miniupnpc/upnpc.c: call WSACleanup()

This commit is contained in:
Thomas Bernard 2014-12-01 10:33:00 +01:00
parent c72591e72e
commit 3a3072ee8c
1 changed files with 7 additions and 1 deletions

View File

@ -1,4 +1,4 @@
/* $Id: upnpc.c,v 1.105 2014/11/01 10:37:32 nanard Exp $ */ /* $Id: upnpc.c,v 1.106 2014/12/01 09:24:31 nanard Exp $ */
/* Project : miniupnp /* Project : miniupnp
* Author : Thomas Bernard * Author : Thomas Bernard
* Copyright (c) 2005-2014 Thomas Bernard * Copyright (c) 2005-2014 Thomas Bernard
@ -768,6 +768,12 @@ int main(int argc, char ** argv)
fprintf(stderr, "No IGD UPnP Device found on the network !\n"); fprintf(stderr, "No IGD UPnP Device found on the network !\n");
retcode = 1; retcode = 1;
} }
#ifdef _WIN32
nResult = WSACleanup();
if(nResult != NO_ERROR) {
fprintf(stderr, "WSACleanup() failed.\n");
}
#endif /* _WIN32 */
return retcode; return retcode;
} }