1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-12-22 10:19:57 +01:00

tests:gpgscm:w32: Fix for GetTempPath.

* tests/gpgscm/ffi.c (do_get_temp_path): Remove the last backslash.

--

Forward port from 2.2 branch of:
	9a75460652d6055983930e80e022396f613ed6f7

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2022-11-22 15:11:42 +09:00
parent 1372b17731
commit 7fe524e182
No known key found for this signature in database
GPG Key ID: 640114AF89DE6054

View File

@ -357,6 +357,11 @@ do_get_temp_path (scheme *sc, pointer args)
#ifdef HAVE_W32_SYSTEM
if (GetTempPath (MAX_PATH+1, buffer) == 0)
FFI_RETURN_STRING (sc, "/temp");
else
{
size_t len = strlen (buffer);
buffer[len-1] = 0;
}
FFI_RETURN_STRING (sc, buffer);
#else
FFI_RETURN_STRING (sc, "/tmp");