Files
Red Bear OS 1b3e94a20d Red Bear OS relibc baseline
From release 0.1.0 pre-patched archive.
This includes all Red Bear modifications previously maintained
as patches in local/patches/relibc/.
2026-06-27 09:19:26 +03:00

21 lines
438 B
C

#include <unistd.h>
#include <fcntl.h>
#include <stdio.h>
#include <stdlib.h>
#include "test_helpers.h"
int main(void) {
int fd = open("example_dir/1-never-gonna-give-you-up", O_RDWR);
ERROR_IF(open, fd, == -1);
UNEXP_IF(open, fd, < 0);
int status = fsync(fd);
ERROR_IF(fsync, status, == -1);
UNEXP_IF(fsync, status, != 0);
int c = close(fd);
ERROR_IF(close, c, == -1);
UNEXP_IF(close, c, != 0);
}