On 14/06/2026 03:26, Christopher Schultz wrote:
Mark,
On 6/13/26 3:08 PM, Mark Thomas wrote:
On 13/06/2026 17:23, Christopher Schultz wrote:
All,
mod_jk for httpd requires APR, which includes its own version of
snprintf, apr_snprintf.
mod_jk for IIS won't usually include APR as a dependency, so we have
to rely on the local Windows environment's implementation of snprintf
which, for very old Windows versions isn't guaranteed.
Have we moved past that, now? Can we rely on Windows always providing
snprintf at this point?
The earliest versions of Windows we need to support are:
- Windows 11
- Windows Server 2016
AI tells me that Visual Studio 2015 is the first version that guarantees
support for snprintf. But it really comes down to the msvcrt.dll used
both to build and also on the target system. Right?
I seem to recall struggling to build various native components when we
are at the mercy of msvcrt.dll. Mark, do you build mod_jk statically for
ISS? Actually, that doesn't make any sense, does it... how much of a
pain is this in Windows-land?
The days of creating Windows binaries that only depend on msvcrt.dll
being present are behind us (thank goodness). These days, every
supported Windows platform has the Universal C RunTime (UCRT or
Universal CRT) so we target that. We continue to avoid any requirement
on any Visual Studio Runtimes.
Looking at:
https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/crt-alphabetical-function-reference?view=msvc-170
we find
https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/snprintf-s-snprintf-s-l-snwprintf-s-snwprintf-s-l?view=msvc-170
so I think you are good to use snprintf if you wish.
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]