Selaa lähdekoodia

test_get_sendfile.c - remove DIR_SEPARATOR_STR (W32 works fine with forwardslashes)

Evgeny Grin (Karlson2k) 12 vuotta sitten
vanhempi
sitoutus
d45a402420
1 muutettua tiedostoa jossa 3 lisäystä ja 3 poistoa
  1. 3 3
      src/testcurl/test_get_sendfile.c

+ 3 - 3
src/testcurl/test_get_sendfile.c

@@ -458,13 +458,13 @@ main (int argc, char *const *argv)
   FILE *f;
 
   if ( (NULL == (tmp = getenv ("TMPDIR"))) &&
-       (NULL == (tmp = getenv ("TMP"))) )
+       (NULL == (tmp = getenv ("TMP"))) &&
+       (NULL == (tmp = getenv ("TEMP"))) )
     tmp = "/tmp";
   sourcefile = malloc (strlen (tmp) + 32);
   sprintf (sourcefile,
-	   "%s%s%s",
+	   "%s/%s",
 	   tmp,
-	   DIR_SEPARATOR_STR,
 	   "test-mhd-sendfile");
   f = fopen (sourcefile, "w");
   if (NULL == f)