From 0474884a87c36fc4e5dfc441bfe0049c2d947bac Mon Sep 17 00:00:00 2001 From: Matthias Koefferlein Date: Wed, 1 Nov 2023 18:23:15 +0100 Subject: [PATCH] Fixed Windows builds --- src/tl/tl/tlFileUtils.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/tl/tl/tlFileUtils.cc b/src/tl/tl/tlFileUtils.cc index 752c4085c..b25a297f6 100644 --- a/src/tl/tl/tlFileUtils.cc +++ b/src/tl/tl/tlFileUtils.cc @@ -1038,7 +1038,7 @@ tmpfile (const std::string &domain) char *tmpstr = strdup (templ.c_str ()); #if defined(_WIN32) - if (_mktemp_s (tmpstr, templ) != 0) { + if (_mktemp_s (tmpstr, templ.size ()) != 0) { free (tmpstr); throw tl::Exception (tl::to_string (tr ("Unable to create temporary folder name in %s")), tmp); } @@ -1092,7 +1092,7 @@ tmpdir (const std::string &domain) char *tmpstr = strdup (templ.c_str ()); #if defined(_WIN32) - if (_mktemp_s (tmpstr, templ) != 0) { + if (_mktemp_s (tmpstr, templ.size ()) != 0) { free (tmpstr); throw tl::Exception (tl::to_string (tr ("Unable to create temporary folder name in %s")), tmp); }