Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2000-11-03* pinfo.cc (pinfo::init): Reverse order of setting status and pid info in anChristopher Faylor
execed process to avoid a race. * sigproc.cc (wait_subproc): Print more info when a WFSO error occurs. * automode.c: New file. * syscalls.cc (close_all_files): Streamline slightly. * cygheap.cc (ccalloc): Clear *entire* allocated array.
2000-10-30* include/cygwin/version.h: Bump DLL minor version number to 6.Christopher Faylor
2000-10-28Whitespace cleanup.Christopher Faylor
* configure.in: Eliminate subdir stuff. * configure: Regenerate. * include/getopt.h (option): Make name field 'const'.
2000-10-24* exceptions.cc (signal_exit): Kill any executing child process if we're dying.Christopher Faylor
* path.h: Remove unneeded extern. * spawn.cc (std_suffixes): Make static. Don't set dwProcessId here since it makes the process unsignalable. Set strace flag that this is an execed process stub. * strace.cc (strace::vsprntf): Use strace flag to indicate when to visually flag that this is an exec stub. * include/sys/strace.h (strace): Add 'execing' flag.
2000-10-17* Makefile.in: Remove some obsolete stuff.Christopher Faylor
* dcrt0.cc (dll_crt0_1): Call signal_fixup_after_exec where appropriate. Set myself->uid from parent version. Just use ThreadItem Init method. Close or store hexec_proc as appropriate. (_dll_crt0): Store user_data->forkee here so that proper tests can be made subsequently. (do_exit): Remove hExeced stuff. * environ.cc (environ_init): Accept environ count as well as environ pointer. * environ.h: Reflect above change. * pinfo.cc (pinfo_init): Ditto. Accept environ count. (fixup_in_spawned_child): Remove. * spawn.cc (spawn_guts): Move signal code to dll_crt0_1. Don't suspend execing process since it is no longer necessary. Store envc. * exceptions.cc (signal_fixup_after_exec): New function. (call_handler): Remove hExeced test. * child_info.h (cygheap_exec_info): Store envc as well as envp. (child_info_spawn): Store hexec_proc so that it can be closed in child. * path.cc (normalize_posix_path): Avoid intermediate use of temporary cwd buf. (normalize_win32_path): Ditto. (cwdstuff::get_initial): Always set lock. * sigproc.h: Remove hExeced. * strace.cc (strace::vsprntf): Modify to accomodate for lack of hExeced. * thread.cc (MTinterface::Init): Merge Init1 and ClearReent into this method. (MTinterface::Init1): Eliminate. (MTinterface::ClearReent): Eliminate. * thread.h: Reflect above changes. * include/sys/strace.h (strace): Make microseconds() public. Make various functions 'regparm', throughout. * pinfo.h (_pinfo): Inline simple signal manipulation functions. Requires inclusion of thread.h which was removed from .cc files, where appropriate. throughout. * pinfo.cc: Eliminate signal manipulation functions. (_pinfo::exit): Calculate total rusage for exiting process here. * cygheap.cc (size2bucket): Eliminate. (init_buckets): Ditto. (_cmalloc): Calculate size and bits in a loop rather than going through a function call. (_crealloc): Use stored array index to calculate allocated size. * spawn.cc (spawn_guts): Use _pinfo exit method to exit, calculating cpu usage.
2000-10-15* exceptions.cc (set_console_handler): Don't allocateChristopher Faylor
console_handler_thread_waiter. It is obsolete. (ctrl_c_handler): Don't use console_handler_thread_waiter. * path.cc (hash_path_name): Fix handling of relative names. Make case insensitive. * path.h (suffix_info): Use initializers. * pinfo.h (_pinfo): Avoid initializers for null case. * resource.cc (fill_rusage): Zero rest of rusage structure. * security.cc (set_process_privileges): Don't reopen parent process. Just use hMainProc. * signal.cc (signal): Track when a signal handler has been used. (sigaction): Ditto. * sigproc.cc (pchildren): Use default initializer. (zombies): Ditto. (sigproc_terminate): Avoid closing handles that will be closed on exit anyway. (wait_sig): Send signal to "parent" on EXECing, not FORKing. (wait_subproc): Send SIGCHLD here rather than in proc_wait to avoid potential muto conflicts. * sigproc.h (sigthread): Don't initialize to zero. It's the default. * spawn.cc (spawn_guts): Fill in resources from exec parent prior to termination. * sync.h (muto): Don't initialize to zero. * syscalls.cc (close_all_files): Use one lock around entire loop and call fhandler close/release stuff directly. (_read): Don't use ready_for_read if there are not signal handlers active. * dcrt0.cc (dll_crt0_1): Fix display of "title". (do_exit): Use pinfo exit method to exit. (__api_fatal): Ditto. * exceptions.cc (signal_exit): Ditto. * fork.cc (fork_child): Remove debugging stuff. Use pinfo_fixup_after fork in place of exec_fixup_after_fork. * pinfo.cc (pinfo_fixup_after_fork): New method. (pinfo_fixup_in_spawned_child): Ditto. (_pinfo::exit): New method. (_pinfo::init): Remove recursion. Detect pathological case where pinfo structure already exists for new pid. * pinfo.h (_pinfo): Reorganize slightly. Add new method and new function declarations. * sigproc.cc (proc_exists): Previous simplification was a little to simple. Try harder to detect if a process exists. (proc_terminate): Use PID_EXITED setting to determine if process is still around. (WFSO): Remove debugging statement. (WFMO): Ditto. * spawn.cc (exec_fixup_after_fork): Eliminate. (spawn_guts): Always set old_title to NULL. Is it really needed? Move hexec_proc to pinfo.cc. Call pinfo_fixup_in_spawned_child to eliminate handle link after a spawn. * include/sys/cygwin.h: Remove PID_NOT_IN_USE. Add PID_EXITED.
2000-10-14 * cygwin.din: Add symbol hstrerror.Corinna Vinschen
* net.cc: Change meaning of member `s' of struct host_errmap. (set_host_errno): Fix error in loop condition. (hstrerror): Ditto. (herror): Add appropriate functionality. * include/netdb.h: Add declaration of hstrerror. * include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR to 29.
2000-10-14Add comment.Christopher Faylor
2000-10-05* include/netinet/tcp.h: Remove winsock.h include.Christopher Faylor
* include/sys/cygwin.h: Move windows specific reference within conditional.
2000-10-05 * include/sys/mman.h: Add missing MAP_FAILED macro.Corinna Vinschen
2000-09-06Dummy file to accomodate programs which includeChristopher Faylor
it unconditionally.
2000-08-26* dcrt0.cc (dll_crt0_1): Move set_os_type.Christopher Faylor
(_dll_crt0): To here. (cygwin_dll_init): And here. * external.cc (fillout_pinfo): Use more foolproof method for scanning for pids. * pinfo.cc (set_myself): Eliminate myself_identity.init. * sigproc.cc (wait_sig): Do it here instead to reduce the amount of time where there could potentially be two processes with the same pid. * spawn.cc (spawn_guts): Eliminate duplicate initialization. * include/sys/cygwin.h: Mark unused PID_* elements.
2000-08-25* external.cc (cygwin_internal): Add CW_INIT_EXCEPTIONS to allow cygwinChristopher Faylor
exception handling on threads not created by cygwin. * sigproc.cc (proc_terminate): Don't release pinfo structs since we are exiting. * include/sys/cygwin.h: Add CW_INIT_EXCEPTIONS.
2000-08-24* include/cygwin/core_dump.h: New file, contains structures used in cygwin coreChristopher Faylor
core files. * include/sys/procfs.h: New file, needed to autoconfigure cygwin core dumps support in bfd.
2000-08-24* include/sys/cygwin.h (strace_printf_wrap): Force printing whenChristopher Faylor
_STRACE_SYSTEM. (strace_printf_wrap1): Ditto.
2000-08-23* include/sys/cygwin.h: Protect class definitions.Christopher Faylor
2000-08-22* include/sys/cygwin.h: Declare some thread classes.Christopher Faylor
* include/mntent.h: Avoid declaring functions.
2000-08-21Update copyright.Christopher Faylor
2000-08-21* include/cygwin/cygwin_dll.h (DECLARE_CYGWIN_DLL): hinstance,DJ Delorie
not handle. (reverse of previous diff)
2000-08-21* include/cygwin/cygwin_dll.h (DECLARE_CYGWIN_DLL): handle,DJ Delorie
not hinstance.
2000-08-11 * poll.cc: Add bounds checking for file descriptors. Return POLLNVALCorinna Vinschen
if fd is invalid. Return POLLERR for each valid fd if cygwin_select returned with error. include/sys/poll.h: Change POLLERR comment according to above change.
2000-08-07* include/cygwin/cygwin_dll.h: Remove extraneous (and incorrect) declarations.Christopher Faylor
2000-08-02* strace.cc (strace::prntf): Make second argument the function name, ratherChristopher Faylor
than use special format options. (strace::vprntf): Ditto. (getfunc): New function. * include/sys/strace.h: Reflect above changes. * smallprint.c (__small_vsprintf): Eliminate '%F' formatting. * pinfo.cc (set_myself): Modify for new strace::prntf parameter. * errno.cc (seterrno_from_win_error): Ditto. * fhandler_tty.cc (fhandler_tty_common::__acquire_output_mutex): Ditto. * fhandler_tty.cc (fhandler_tty_common::__release_output_mutex): Ditto.
2000-08-02* include/sys/strace.h: Fix strace definition.Christopher Faylor
2000-08-02* strace.h: Add kludgy workarounds to avoid using deprecated methods forChristopher Faylor
variable argument macros when possible. * sigproc.cc: Throughout, use sigproc_printf rather than sip_printf. * strace.cc (strace::prntf): Remove 'active' check, since callers are supposed to ensure this. (__system_printf): Remove. Subsumed by strace::prntf. * winsup.h: Define "NEW_MACRO_VARARGS" to indicate when to use new macro varargs capability.
2000-07-29* include/cygwin/version.h: Bump DLL minor version number to 5 due to all ofChristopher Faylor
the changes below. Redefine process structure to avoid a fixed size table. Redefine pinfo/_pinfo classes. Use these throughout. * dcrt0.cc (dll_crt0_1): Accomodate set_myself argument change. (__api_fatal): Accomodate _pinfo::record_death argument change. * exceptions.cc (really_exit): Ditto. (sig_handle_tty_stop): Use pinfo constructor to access process info. (events_init): Don't create pinfo_mutex since it is no longer required. * external.cc (fillout_pinfo): Use winpids class to iterate over all system pids. (cygwin_internal): lock_pinfo_for_update and unlock_pinfo are now noops. * fhandler_termios.cc (fhandler_termios::set_ctty): Use pinfo constructor to access process info. * fork.cc (fork): Reorganize to initialize child info after the child has started since that is when we know the child's winpid, which is necessary to allocate the pinfo shared memory. * mmap.cc (recreate_mmaps_after_fork): Change arg type to _pinfo. * pinfo.cc: Rename pinfo methods to _pinfo throughout. Eliminate pinfo_list stuff. (set_myself): Accept a pid argument now. Call pinfo initializer to initialize myself. Detect when this is an "execed" process and create an "indirect" pid block. (pinfo_init): Accomodate set_myself arg change. (procinfo): Remove. (pinfo::lock_pinfo): Remove. (pinfo::unlock_pinfo): Remove. (pinfo::init): New method. Allocates shared memory space for process pinfo structure. (pinfo::record_death): Don't call locking functions. (cygwin_winpid_to_pid): Simplify by using new pinfo constructor. (EnumProcessesW95): New function for iterating over processes on Windows 95. (winpids::winpids): New constructor for winpids class. Sets up a list of process ids. (enum_init): Initialize w95/wnt pid enumerators. * shared.cc (shared-info::initialize): Remove pid initialization. * shared.h: Move pinfo stuff into pinfo.h. (class shared_info): Remove pinfo_list element. * signal.cc (kill_worker): Use pinfo constructor to access process info. (kill_pgrp): Ditto. Use winpids methods to access list of processes. * sigproc.cc: Throughout, modify to use _pinfo where appropriate. (proc_exists (pid_t)): New function. Determines if a process exists based on the pid. (proc_exists (_pinfo *p): Use new proc_exists function above. (proc_subproc): Copy pinfo stuff around rather than _pinfo pointers. Try to be careful about releasing shared memory when we don't need it anymore. Remove pinfo locks. (remove_zombies): Remove pinfo memory when zombie is going away. * sigproc.h: Reflect _pinfo/pinfo changes in sigproc.cc. * spawn.cc (spawn_guts): Eliminate pinfo *child argument. Reorganize to only initialize child pinfo after process has been started and we know the windows pid. (_spawnve): Reflect spawn_guts changes. * syscalls.cc (setpgid): Use pinfo constructor to access process info. (getpgid): Ditto. (internal_getlogin): Use _pinfo. * winsup.h: Eliminate pinfo_mutex. Eliminate spawn_guts declaration since it is static now. Reflect set_myself argument change. * include/sys/cygwin.h: Add some PID_* enums to accomodate new pinfo stuff. * include/cygwin/version.h: Update minor version for cygdrive changes below.
2000-07-29* include/cygwin/cygwin_dll.h: Update for modern compilers.Christopher Faylor
* lib/cygwin_crt0.c: Inexplicably need to define alloca for newer compilers. * fhandler.h (fhandler_console): Add new method. * fhandler.cc (fhandler_console::set_cursor_maybe): New method. (fhandler_console::read): Set cursor if it has moved to make it visible.
2000-07-29* dcrt0.cc (dummy_autoload): Add load statement for RegDeleteValueA.Christopher Faylor
* external.cc (get_cygdrive_prefixes): New function. (cygwin_internal): Add CW_GET_CYGDRIVE_PREFIXES case. * path.cc (mount_info::read_cygdrive_info_from_registry): Read system cygdrive prefix if user one is undefined. (mount_info::write_cygdrive_info_to_registry): Write cygdrive prefix to the appropriate registry hive. Overwrite in-memory copy of cygdrive, if appropriate. (mount_info::remove_cygdrive_info_from_registry): New method. (mount_info::get_cygdrive_prefixes): New method. (cygwin_umount): Remove cygdrive prefix, if appropriate. * registry.cc (reg_key::killvalue): New method. * shared.h (class reg_key): Add killvalue, remove_cygdrive_info_to_registry, and get_cygdrive_prefixes declarations. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_GET_CYGDRIVE_PREFIXES.
2000-07-28* include/cygwin/version.h: Bump DLL minor version number to 4.Christopher Faylor
2000-07-09* cygwin.din: Export _getmode and getmode to allow querying of binary state ofChristopher Faylor
an fd. * external.cc (cygwin_internal): Add handling of perfile_table setting. * fhandler.cc (perfile_table): New global. (fhandler_base::get_default_fmode): New method to return a file's default mode based on its name. (fhandler_base::open): Use get_default_mode method to determine a file's mode. Record file mode in file flags. * fhandler.h (fhandler_base): Declare get_default_fmode * syscalls.cc (getmode): New function. * sys/cygwin.h (__cygwin_perfile): New structure. (cygwin_getinfo_types): Move outside of WINVER conditional. (per_process): Move inside of WINVER conditional.
2000-07-08* external.cc (cygwin_internal): Export __cygwin_user_data.Christopher Faylor
* include/sys/cygwin.h: Allow definition of per_process even when not compiling with C++. (cygwin_getinfo_types): Add CW_USER_DATA. * lib/_cygwin_crt0_common.cc (_cygwin_crt0_common): Get __cygwin_user_data pointer from cygwin_internal. If it doesn't exist, return failure. Use either this pointer or passed in pointer throughout. Clear forkee. * lib/crt0.h: Accomodate argument changes to _cygwin_crt0_common. * lib/cygwin_attach_dll.c (cygwin_attach_dll): Reorganize to allow use of newer binaries with older DLLs. Detect older DLLs when _cygwin_crt0_common returns 0 and allocate space for a per_process structure on the stack. * lib/cygwin_crt0.c (cygwin_crt0): Ditto.
2000-07-07 * include/sys/cygwin.h: Hide internal data types in per_processCorinna Vinschen
when not __INSIDE_CYGWIN__.
2000-07-06* dcrt0.cc (__cygwin_user_data): Initialize.Christopher Faylor
(dll_crt0_1): Eliminate user_data initialization. (dll_crt0): Set up impure_ptr_ptr for older executables. (cygwin_dll_init): Eliminate user_data initializations. (__api_fatal): Don't check for user_data initialization. * dll_init.cc (struct dll): Store entire contents of per_process rather than just a pointer. (add): Ditto. (initOneDll): Don't check for user_data initialization. (DllList::recordDll): Store contents of per_process argument. (DllList::detachDll): Pass address of per_process field. (DllList::initAll): Ditto. (DllList::doGlobalDestructorsOfDlls): Ditto. (DllListIterator::operator *): Ditto. (dll_dllcrt0): Default to __cygwin_user_data if arg is NULL. * include/sys/cygwin.h: Reorganize per_process to eliminate obsolete fields and accomodate new way of initializing. * lib/_cygwin_crt0_common: Initialize _impure_ptr from __cygwin_user_data.impure_ptr.
2000-07-04 * include/cygwin/version.h: Bump API minor version to 24.Corinna Vinschen
2000-07-04 * poll.cc: New file. Implement `poll' system call.Corinna Vinschen
* include/poll.h: Ditto. * include/sys/poll.h: Ditto. * Makefile.in: Add poll.o as dependency. * cygwin.din: Add poll and _poll symbols.
2000-07-03 * include/cygwin/socket.h: Remove SOCK_PACKET define since it'sCorinna Vinschen
not supported by Windows sockets.
2000-07-01* Makefile.in: Use variables rather than configure constructs whereChristopher Faylor
appropriate. (LIBCOS): Find additional stub library stuff in their own subdirectory. * dcrt0.cc: Convert user_data pointer to static __cygwin_user_data area. (do_global_ctors): Check magic_bisquit for initialization. (dll_crt0_1): First group of premain functions prior to fd initialization. Run second group before calling main. (dll_crt0 ()): New function, called from new initialization code. (dll_crt0 (per_process *uptr)): Call new dll_crt0 () function on initialization. * debug.cc (thread_stub): Initialize bottom of stack with per-thread info. * environ.cc (parse_thing): Use binmode global to control CYGWIN=binmode behavior. * fhandler.cc (fhandler_base::open): Allow explicit setting of __fmode to O_BINARY or O_TEXT to override disk mount settings. * libcmain.cc: Move to lib subdirectory. * libccrt0.cc: Ditto. * dll_main.cc: Ditto. * dll_entry.cc: Ditto. * getopt.c: Ditto. * thread.cc (thread_init_wrapper): Call ExitThread explicitly rather than returning, as a preliminary step towards placing per thread info at the bottom of the stack. * winsup.h: Move per_process class to include/sys/cygwin.h. Declare new dll_crt0(). * include/cygwin/version.h: Bump API minor version. * binmode.c: New file. * textmode.c: Ditto. * lib/_cygwin_crt0_common.cc: Ditto. * lib/crt0.h: Ditto. * lib/cygwin_attach_dll.c: Ditto. * lib/cygwin_crt0.c: Ditto. * lib/dll_entry.cc: Ditto. * lib/dll_main.cc: Ditto. * lib/getopt.c: Ditto. * lib/libcmain.c: Ditto. * lib/premain0.c: Ditto. * lib/premain1.c: Ditto. * lib/premain2.c: Ditto. * lib/premain3.c: Ditto.
2000-06-23* Makefile.in: Autogenerate cygwin.def when appropriate.Christopher Faylor
* include/sys/cygwin.h: Correct prototype.
2000-06-23Revise previous include/sys/cygwin.h change.Christopher Faylor
2000-06-23* include/sys/cygwin.h: Don't define parts of this file that rely on WindowsChristopher Faylor
headers unless the Windows header was previously included.
2000-06-21* Makefile.in: Add *.def to clean operation.Christopher Faylor
2000-06-16 * cygwin.din: Define symbols for `cygwin_logon_user' andCorinna Vinschen
`cygwin_set_impersonation_token'. * dcrt0.cc (dll_crt0_1): Eliminate superfluous conditional statements. Add load statements for `ImpersonateLoggedOnUser', `LogonUserA' and `RevertToSelf'. * fork.cc (fork): Care for correct impersonation of parent and child process. * security.cc (cygwin_set_impersonation_token): New function. (cygwin_logon_user): Ditto. shared.h (class pinfo): New members `orig_uid', `orig_gid', `real_uid' nad `real_gid'. spawn.cc (spawn_guts): Care for impersonation when starting child process in a different user context. * syscalls.cc (setgid): Call `setegid' now. Set real_gid. (setuid): Call `seteuid' now. Set real_uid. (seteuid): Functionality moved from setuid to here. Care for correct impersonation. (setegid): Functionality moved from setgid to here. * uinfo.cc (uinfo_init): Initialization of additional pinfo members. (getuid): Return real uid. (getgid): Return real gid. (geteuid): Return effective uid. (getegid): Return effective gid. include/sys/cygwin.h: Add prototypes for `cygwin_logon_user' and `cygwin_set_impersonation_token'. include/cygwin/version.h: Bumb API minor version to 22.
2000-06-08* include/cygwin/version.h: Bump DLL minor version number to 3.Christopher Faylor
2000-06-07 * include/netinet/in_systm.h: New file.Corinna Vinschen
* include/cygwin/in_systm.h: Ditto.
2000-05-31* include/cygwin/version.h: use decimal, NOT octalDJ Delorie
2000-05-24* syscalls.cc (_cygwin_istext_for_stdio): New, for newlibDJ Delorie
* include/cygwin/version.h: Bump API number for detect old programs using old getc/putc macros
2000-05-18* select.cc (thread_pipe): Add paranoid check to ensure thread termination.Christopher Faylor
* external.cc: Eliminate obsolete include. * getopt.c (getopt_long): Fix compiler warning. * shared.h: Moved PID_ definitions to include/sys/cygwin so that they can be used by external programs. * include/sys/cygwin.h: Move external definitions here. Include sys/resource.h to avoid having to do this everywhere.
2000-05-16* include/cygwin/in.h (AF_INET6): Use correct in6_addr struct.Christopher Faylor
2000-05-15* include/cygwin/version.h: Bump DLL minor version number to 2.Christopher Faylor
2000-05-15* shared.h: Bump PROC_MAGIC.Christopher Faylor
* include/cygwin/version.h: Bump API minor to accomodate two recent exports.