Unverified Commit 5908e900 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

unit1651: survive curl_easy_init() fails

parent 21b33b9a
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -5,7 +5,7 @@
 *                            | (__| |_| |  _ <| |___
 *                             \___|\___/|_| \_\_____|
 *
 * Copyright (C) 2018, Daniel Stenberg, <daniel@haxx.se>, et al.
 * Copyright (C) 2018 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al.
 *
 * This software is licensed as described in the file COPYING, which
 * you should have received as part of this distribution. The terms
@@ -352,6 +352,8 @@ UNITTEST_START
  struct Curl_easy *data = curl_easy_init();
  int i;
  int byte;
  if(!data)
    return 2;

  memset(&conn, 0, sizeof(struct connectdata));
  /* this is a lot of assuming, but we expect the parsing function to only