mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
gpgscm: Fix creation of temporary directories.
* tests/gpgscm/ffi.c (do_mkdtemp): Use a larger buffer for the template. Signed-off-by: Justus Winter <justus@g10code.com>
This commit is contained in:
parent
e3589110e0
commit
171e4314eb
@ -26,6 +26,7 @@
|
||||
#include <errno.h>
|
||||
#include <fcntl.h>
|
||||
#include <gpg-error.h>
|
||||
#include <limits.h>
|
||||
#include <stdarg.h>
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
@ -345,7 +346,11 @@ do_mkdtemp (scheme *sc, pointer args)
|
||||
{
|
||||
FFI_PROLOG ();
|
||||
char *template;
|
||||
char buffer[128];
|
||||
#ifdef PATH_MAX
|
||||
char buffer[PATH_MAX];
|
||||
#else
|
||||
char buffer[1024];
|
||||
#endif
|
||||
char *name;
|
||||
FFI_ARG_OR_RETURN (sc, char *, template, string, args);
|
||||
FFI_ARGS_DONE_OR_RETURN (sc, args);
|
||||
|
Loading…
x
Reference in New Issue
Block a user