freebsd-nq/contrib/mandoc/test-mkstemps.c
Baptiste Daroussin 6d38604fc5 mandoc: import version 1.14.6
MFC after: 3 weeks
2021-11-15 16:58:58 +01:00

13 lines
185 B
C

#include <stdlib.h>
#include <unistd.h>
int
main(void)
{
char filename[] = "/tmp/temp.XXXXXX.suffix";
if (mkstemps(filename, 7) == -1)
return 1;
return unlink(filename) == -1;
}