some windows fixes for unit tests

This commit is contained in:
Arvid Norberg
2013-07-23 07:32:38 +00:00
parent be737976d4
commit c0da76ac84
2 changed files with 13 additions and 7 deletions

View File

@@ -133,6 +133,12 @@ int run_upnp_test(char const* root_filename, char const* router_model, char cons
buf.push_back(0);
FILE* xml_file = fopen("upnp.xml", "w+");
if (xml_file == NULL)
{
fprintf(stderr, "failed to open file 'upnp.xml': %s\n", strerror(errno));
TEST_CHECK(false);
return 1;
}
fprintf(xml_file, &buf[0], g_port);
fclose(xml_file);