mirror of
https://github.com/Zenithsiz/ftmemsim-valgrind.git
synced 2026-02-12 14:20:04 +00:00
file descriptors came into existence, because there's too much variation and all the expected outputs are a pain. This allows 16 fdleak_*.exp[234] files to be removed. Also remove an unnecessary newline in a tmp filename in fdleak_creat.c. git-svn-id: svn://svn.valgrind.org/valgrind/trunk@9194
22 lines
276 B
C
22 lines
276 B
C
#include <unistd.h>
|
|
#include <stdio.h>
|
|
#include <fcntl.h>
|
|
#include "fdleak.h"
|
|
int
|
|
main (int argc, char **argv)
|
|
{
|
|
char filename[24];
|
|
|
|
|
|
|
|
|
|
|
|
|
|
CLOSE_INHERITED_FDS;
|
|
|
|
sprintf(filename, "/tmp/file.%d", getpid());
|
|
creat(filename, 0);
|
|
unlink(filename);
|
|
return 0;
|
|
}
|