1/* This file is used to test the 'catch syscall' feature on GDB.
2
3   Please, if you are going to edit this file DO NOT change the syscalls
4   being called (nor the order of them).  If you really must do this, then
5   take a look at catch-syscall.exp and modify there too.
6
7   Written by Sergio Durigan Junior <sergiodj@linux.vnet.ibm.com>
8   September, 2008 */
9
10#include <unistd.h>
11#include <fcntl.h>
12#include <sys/stat.h>
13
14int
15main (void)
16{
17	/* A close() with a wrong argument.  We are only
18	   interested in the syscall.  */
19	close (-1);
20
21	chroot (".");
22
23	/* The last syscall.  Do not change this.  */
24	_exit (0);
25}
26