]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
ftp: disable warning 4706 in MSVC
authorDaniel Stenberg <daniel@haxx.se>
Mon, 3 Jan 2022 15:04:32 +0000 (16:04 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Mon, 3 Jan 2022 16:05:13 +0000 (17:05 +0100)
Follow-up to 21248e052d

Disabling "assignment within conditional expression" for MSVC needs to
be done before the function starts, for it to take effect.

Closes #8218

lib/ftp.c

index ce7f9c20370047d750d4b032ff07dc87793ad41c..f6921e42620cd207420dc18c6eaeffed0f45130b 100644 (file)
--- a/lib/ftp.c
+++ b/lib/ftp.c
@@ -5,7 +5,7 @@
  *                            | (__| |_| |  _ <| |___
  *                             \___|\___/|_| \_\_____|
  *
- * Copyright (C) 1998 - 2021, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) 1998 - 2022, 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
@@ -4102,6 +4102,11 @@ static CURLcode ftp_disconnect(struct Curl_easy *data,
   return CURLE_OK;
 }
 
+#ifdef _MSC_VER
+/* warning C4706: assignment within conditional expression */
+#pragma warning(disable:4706)
+#endif
+
 /***********************************************************************
  *
  * ftp_parse_url_path()