summaryrefslogtreecommitdiff
path: root/newlib/libc/syscalls/sysfork.c
blob: 9fe319ff0df80fc5ec36397b7f2b001ca0abc466 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
/* connector for fork */

/* Don't define this if NO_FORK.  See for example libc/sys/win32/spawn.c.  */

#ifndef NO_FORK

#include <reent.h>

int
fork ()
{
#ifdef REENTRANT_SYSCALLS_PROVIDED
  return _fork_r (_REENT);
#else
  return _fork ();
#endif
}

#endif