(root)/
strace-6.5/
tests-mx32/
epoll_create1.c
       1  /*
       2   * Check decoding of epoll_create1 syscall.
       3   *
       4   * Copyright (c) 2015-2018 Dmitry V. Levin <ldv@strace.io>
       5   * Copyright (c) 2015-2021 The strace developers.
       6   * All rights reserved.
       7   *
       8   * SPDX-License-Identifier: GPL-2.0-or-later
       9   */
      10  
      11  #include "tests.h"
      12  #include "scno.h"
      13  
      14  #include <stdio.h>
      15  #include <unistd.h>
      16  #include "kernel_fcntl.h"
      17  
      18  int
      19  main(void)
      20  {
      21  	long rc = syscall(__NR_epoll_create1, O_CLOEXEC);
      22  	printf("epoll_create1(EPOLL_CLOEXEC) = %s\n", sprintrc(rc));
      23  
      24  	rc = syscall(__NR_epoll_create1, O_CLOEXEC | O_NONBLOCK);
      25  	printf("epoll_create1(EPOLL_CLOEXEC|%#x) = %s\n",
      26  	       O_NONBLOCK, sprintrc(rc));
      27  
      28  	puts("+++ exited with 0 +++");
      29  	return 0;
      30  }