/* fork.c (emx+gcc) -- Copyright (c) 1992-1996 by Eberhard Mattes */

#include <process.h>
#include <emx/syscalls.h>

extern void _rmutex_fork (void);

int _fork (void)
{
  int pid;

  pid = __fork ();
#if defined (__MT__)
  if (pid == 0)
    _rmutex_fork ();
#endif
  return pid;
}
