From ba94682838272afc87b73833c02aaf6cea40815e Mon Sep 17 00:00:00 2001 From: Corinna Vinschen Date: Wed, 12 Sep 2001 17:46:37 +0000 Subject: * Makefile.in: Build wincap.o. * wincap.cc: New file. * wincap.h: Ditto. * autoload.cc: Add dynamic load statement for `CreateHardLinkA'. * dcrt0.cc (os_being_run): Eliminated. (osname): Ditto. (iswinnt): Ditto. (set_os_type): Ditto. (dll_crt0_1): Call wincap.init() instead of set_os_type(). (_dll_crt0): Ditto. * environ.cc (set_chunksize): New function. (parse_thing): `forkchunk' setting now invokes function `set_chunksize'. * fork.cc (chunksize): Eliminated. Moved to be member of wincap. * host_dependent.h: Removed. * syscalls.cc (_link): Try using `CreateHardLinkA' first, if available. * cygheap.cc, dcrt0.cc, delqueue.cc, dir.cc, environ.cc, fhandler.cc, fhandler.h, fhandler_console.cc, fhandler_mem.cc, fork.cc, mmap.cc, net.cc, pinfo.cc, pinfo.h, security.cc, syscalls.cc, sysconf.cc, syslog.cc, thread.cc, times.cc, tty.cc, uinfo.cc, uname.cc, winsup.h: Use new wincap capability check throughout. * winsup.h: Include wincap.h. Eliminate extern declarations of `os_being_run' and `iswinnt'. Eliminate `os_type" definition. * include/cygwin/version.h: Bump version to 1.3.4. --- winsup/cygwin/fork.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'winsup/cygwin/fork.cc') diff --git a/winsup/cygwin/fork.cc b/winsup/cygwin/fork.cc index ccfc2aa26..3998cb56b 100644 --- a/winsup/cygwin/fork.cc +++ b/winsup/cygwin/fork.cc @@ -35,7 +35,6 @@ static int npid_max; static pid_t fork_pids[100]; #endif -DWORD NO_COPY chunksize = 0; /* Timeout to wait for child to start, parent to init child, etc. */ /* FIXME: Once things stabilize, bump up to a few minutes. */ #define FORK_WAIT_TIMEOUT (300 * 1000) /* 300 seconds */ @@ -87,7 +86,7 @@ fork_copy (PROCESS_INFORMATION &pi, const char *what, ...) while ((low = va_arg (args, char *))) { char *high = va_arg (args, char *); - DWORD todo = chunksize ?: high - low; + DWORD todo = wincap.chunksize () ?: high - low; char *here; for (here = low; here < high; here += todo) -- cgit v1.2.3