Commit c3031073 authored by Dan Fandrich's avatar Dan Fandrich
Browse files

test585: Fixed NULL pointer dereference in fopen

parent 3d77d013
Loading
Loading
Loading
Loading
+36 −35
Original line number Diff line number Diff line
@@ -91,9 +91,9 @@ int test(char *URL)
  res = curl_easy_perform(curl);

  if(!res) {
    FILE *moo;
    res = curl_easy_getinfo(curl, CURLINFO_PRIMARY_IP, &ipstr);
    moo = fopen(libtest_arg2, "wb");
    if (libtest_arg2) {
      FILE *moo = fopen(libtest_arg2, "wb");
      if(moo) {
	double time_namelookup;
	double time_connect;
@@ -130,6 +130,7 @@ int test(char *URL)
	fclose(moo);
      }
    }
  }

test_cleanup: