Paul Floyd 7c5d720a2b FreeBSD support, patch 10
memcheck
No code changes. A few modified tests. Adds new FreeBSD specific tests.
2021-10-09 12:37:17 +02:00

22 lines
403 B
C

#include <sys/stat.h>
#include <unistd.h>
#include <fcntl.h>
#include <string.h>
#include <stdlib.h>
int main()
{
const char* filename = strdup("revoke.tst");
(void)open(filename, O_RDWR | O_CREAT, S_IRUSR | S_IWUSR);
// add a gratuitous syscall
(void)getdtablesize();
// OK
revoke(filename);
// with an invalid param
free((void*)filename);
revoke(filename);
}