Viktor Szakats

Results 206 comments of Viktor Szakats

Another option is to set `-DDEBUGBUILD` unconditionally when both `ENABLE_DEBUG=ON` and `BUILD_TESTING=ON` are set. edit: Not good because `BUILD_TESTING` is `ON` by default (except when Perl is missing or `CURL_DISABLE_TESTS`...

Another solution is to require `Debug` builds for `BUILD_TESTING`. The disadvantage of this is that some might use `CMAKE_C_FLAGS=-DDEBUGBUILD`, which also works, but fails this condition.

What I've found so far is that running or building tests don't require `DEBUGBUILD`, but building them with `CURLDEBUG` does. The problem is that `ENABLE_DEBUG` always sets the latter, but...

Settled with the original concept to always enable `-DDEBUGBUILD` when `ENABLE_DEBUG=ON`.

> I take issue with "too easy" being a bad thing. My thinking is if the user has made a choice to enable curl debug builds then why would we...

> Seems right to me since it's documented as enabling curl debug features. Thanks! > It's confusing that --enable-debug and ENABLE_DEBUG are not exactly the same since ENABLE_DEBUG does not...

There exists one more variant: `explicit_memset`: ```cmake check_symbol_exists("explicit_memset" "string.h" HAVE_EXPLICIT_MEMSET) ``` ```c #define _libssh2_explicit_zero(buf, size) (void)explicit_memset(buf, 0, size) ``` https://man.netbsd.org/explicit_memset.3 It's checked after `explicit_bzero` and before `memset_s` in libssh2.

In libssh2 the wrapper for all the variants is a macro. It has the advantage to inline the native Windows call (and maybe others if they have a similar implementation)....

> > In libssh2 the wrapper for all the variants is a macro. It has the advantage to inline the native Windows call (and maybe others if they have a...

``` unity_0_c.c(CMakeFiles/curl.dir/Unity/unity_0_c.c.o:(create_dir_hierarchy)): warning: strcpy() is almost always misused, please use strlcpy() ``` Ref: https://github.com/curl/curl/actions/runs/9033005218/job/24822356703?pr=13583#step:3:421