0001-curl_trc-fix-build-with-verbose-messages-disabled.patch 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. From 58d490091d097ba2ad108cc66c97e242e5aacb9c Mon Sep 17 00:00:00 2001
  2. Message-ID: <58d490091d097ba2ad108cc66c97e242e5aacb9c.1727153835.git.baruch@tkos.co.il>
  3. From: Baruch Siach <baruch@tkos.co.il>
  4. Date: Tue, 24 Sep 2024 07:52:13 +0300
  5. Subject: [PATCH] curl_trc: fix build with verbose messages disabled
  6. Add empty definition of Curl_trc_ws() to fix this following build error:
  7. In file included from sendf.h:29,
  8. from ws.c:35:
  9. ws.c: In function 'Curl_ws_accept':
  10. curl_trc.h:100:10: error: implicit declaration of function 'Curl_trc_ws'; did you mean 'Curl_trc_ftp'? [-Wimplicit-function-declaration]
  11. 100 | Curl_trc_ws(data, __VA_ARGS__); } while(0)
  12. | ^~~~~~~~~~~
  13. ws.c:779:5: note: in expansion of macro 'CURL_TRC_WS'
  14. 779 | CURL_TRC_WS(data, "WS, using chunk size %zu", chunk_size);
  15. | ^~~~~~~~~~~
  16. Signed-off-by: Baruch Siach <baruch@tkos.co.il>
  17. Upstream: https://github.com/curl/curl/pull/15026
  18. ---
  19. lib/curl_trc.h | 6 ++++++
  20. 1 file changed, 6 insertions(+)
  21. diff --git a/lib/curl_trc.h b/lib/curl_trc.h
  22. index 5f675b453fd3..1801d33cea7c 100644
  23. --- a/lib/curl_trc.h
  24. +++ b/lib/curl_trc.h
  25. @@ -226,6 +226,12 @@ static void Curl_trc_smtp(struct Curl_easy *data, const char *fmt, ...)
  26. (void)data; (void)fmt;
  27. }
  28. #endif
  29. +#if defined(USE_WEBSOCKETS) && !defined(CURL_DISABLE_HTTP)
  30. +static void Curl_trc_ws(struct Curl_easy *data, const char *fmt, ...)
  31. +{
  32. + (void)data; (void)fmt;
  33. +}
  34. +#endif
  35. #endif /* !defined(CURL_DISABLE_VERBOSE_STRINGS) */
  36. --
  37. 2.45.2