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
2001-09-20 * fhandler_socket.cc (fhandler_socket::fixup_after_exec): CloseCorinna Vinschen
socket only when not using Winsock2.
2001-09-20 * fhandler.h (fhandler_socket::fixup_after_exec): Remove inlineCorinna Vinschen
implementation. (fhandler_dev_raw::fixup_after_exec): Ditto. * fhandler_raw.cc (fhandler_dev_raw::fixup_after_fork): Don't duplicate buffer on fork to avoid memory leak. (fhandler_dev_raw::fixup_after_exec): New implementation equal to former fixup_after_fork() implementation. * fhandler_socket.cc (fhandler_socket::fixup_after_fork): Do nothing when not using Winsock2. (fhandler_socket::fixup_after_exec): New implementation. (fhandler_socket::set_close_on_exec): Never call set_inheritance().
2001-09-19 * fhandler_socket.cc (fhandler_socket::fhandler_socket): RevertCorinna Vinschen
memory allocation to use cmalloc again.
2001-09-08* cygheap.h (init_cygheap): Move heap pointers here.Christopher Faylor
* include/sys/cygwin.h (perprocess): Remove heap pointers. * dcrt0.cc (__cygwin_user_data): Reflect obsolete perprocess stuff. (_dll_crt0): Don't initialize heap pointers. (cygwin_dll_init): Ditto. (release_upto): Use heap pointers from cygheap. * heap.h: Ditto. * fork.cc (fork_parent): Ditto. Don't set heap pointers in ch. (fork_child): Remove obsolete sigproc_fixup_after_fork. * shared.cc (memory_init): Reorganize so that cygheap initialization is called prior to regular heap since regular heap uses cygheap now. * sigproc.cc (proc_subproc): Eliminate zombies allocation. (sigproc_init): Move zombies alloation here. Don't free up array on fork, just reuse it. (sigproc_fixup_after_fork): Eliminate. * sigproc.h: Ditto. * include/cygwin/version.h: Reflect change to perprocess structure.
2001-09-07* fhandler_socket.cc (fhandler_socket::fhandler_socket): Ensure thatChristopher Faylor
prot_info_ptr is zeroed for later use.
2001-09-06Remove initialization of static or global values to zero, throughout. ThisChristopher Faylor
just needlessly grows the size of the DLL. * tty.cc (tty::alive): Make inuse handle non-inheriting on open, just for thread safety.
2001-09-05 * fhandler_socket.cc (fhandler_socket::close): Change 2MSL valueCorinna Vinschen
according to MSDN.
2001-08-16* fhandler_socket.cc (fhandler_socket::create_secret_event): RelaxEgor Duda
security of secret_event so AF_UNIX socket clients can connect to servers even if running under a different user account. (fhandler_socket::check_peer_secret_event): Ditto.
2001-08-15 * fhandler.cc (fhandler_base::is_nonblocking): New method.Corinna Vinschen
(fhandler_base::set_nonblocking): Ditto. * fhandler.h (fhandler_base): Declare new methods `is_nonblocking' and `set_nonblocking'. * fhandler_socket.cc (fhandler_socket::ioctl): Use `set_nonblocking'. * fhandler_tty.cc (fhandler_pty_master::process_slave_output): Use `is_nonblocking'. (fhandler_tty_slave::read): Ditto. (fhandler_tty_slave::ioctl): Use `set_nonblocking'. (fhandler_pty_master::ioctl): Ditto. * net.cc (cygwin_sendto): Fallback to winsock 1 functionality in case of nonblocking IO. (cygwin_recvfrom): Ditto. (cygwin_recv): Ditto. (cygwin_send): Ditto. * syscalls.cc (_read): Use `is_nonblocking'.
2001-08-14 * fhandler.cc (fhandler_base::fcntl): Use new O_NONBLOCK_MASK define.Corinna Vinschen
* fhandler.h: Move definitions of O_NOSYMLINK, O_DIROPEN and OLD_O_NDELAY from winsup.h to here. Add O_NONBLOCK_MASK define. * fhandler_socket.cc (fhandler_socket::close): Add hack to allow a graceful shutdown even if shutdown() hasn't been called by the application. Add debug output. (fhandler_socket::ioctl): Set fhandler's NONBLOCK flag according to FIONBIO setting. (fhandler_socket::fcntl): Use new O_NONBLOCK_MASK define. Actually set `request' before using it. * fhandler_tty.cc: Use new O_NONBLOCK_MASK define throughout. (fhandler_tty_slave::ioctl): Set fhandler's NONBLOCK flag according to FIONBIO setting. (fhandler_pty_master::ioctl): Ditto. * net.cc (wsock_event::prepare): Compare WSACreateEvent return code with `WSA_INVALID_EVENT' according to MSDN. * syscalls.cc (_read): Use new O_NONBLOCK_MASK define.
2001-08-07* cygheap.cc (cygheap_root::set): Avoid treating '/' specially.Christopher Faylor
* fhandler.cc (fhandler_base::fcntl): Only set specific O_NDELAY style flag passed in from application. * fhandler_socket.cc (fhandler_socket::fcntl): Ditto. * fhandler.h: Set constant for future use. * winsup.h: Define OLD_O_NDELAY only for old programs. * include/cygwin/version.h: Define CYGWIN_VERSION_CHECK_FOR_OLD_O_NONBLOCK.
2001-07-26Throughout, reorganize header file inclusion to put security.h prior toChristopher Faylor
fhandler.h. * fhandler.h (fhandler_base::get_inheritance): New method. * fhandler_socket.cc (fhandler_socket::create_secret_event): Use proper close-on-exec inheritance when creating. (fhandler_socket::check_peer_secret_event): Create handle as non-inheritable.
2001-06-23 * fhandler.h class fhandler_socket): Declare new methodCorinna Vinschen
`set_close_on_exec'. * fhandler_socket.cc (fhandler_socket::set_close_on_exec): New method.
2001-06-20* fhandler_socket.cc (fhandler_socket::signal_secret_event): NewEgor Duda
function. * fhandler.h: Declare it. * fhandler_socket.cc (fhandler_socket::create_secret_event): Don't signal secret event immediately. (fhandler_socket::check_peer_secret_event): Do it after peer event was opened. * net.cc (cygwin_connect): Or if socket is non-blocking. (cygwin_accept): Ditto.
2001-05-15 * fhandler_socket.cc (fhandler_socket::ioctl): Convert s_addrCorinna Vinschen
field to host byte order before comparing with INADDR_LOOPBACK.
2001-05-04* fhandler_socket.cc (set_connect_secret): Use /dev/urandom toEgor Duda
generate secret cookie.
2001-04-19Throughout, change fdtab references to cygheap->fdtab.Christopher Faylor
* child_info.h (cygheap_exec_info): Eliminate special fdtab stuff. * spawn.cc (spawn_guts): Ditto. * cygheap.cc (cygheap_init): Initialize fdtab, if appropriate. * cygheap.h (CYGHEAPSIZE): Include size of init_cygheap. (_cmalloc_entry): Include fdtab here. * dtable.h (dtable): Declare/define new methods. * dtable.cc (dtable::vfork_child_fixup): New method. (dtable::fixup_after_exec): Remove unneeded extra arguments. * dcrt0.cc (dll_crt0_1): Ditto. * environ.cc (getwinenv): Use case sensitive comparison. (winenv): Make a copy of environment cache to avoid realloc problems when duplicate environment variables exist in the environment. (From Egor Duda) * net.cc (cygwin_socket): Revert Apr 14 change. * include/sys/file.h: Protect against previous X_OK definition. * passwd.cc: Eliminate passwd_sem throughout. * security.cc: Ditto. * cygwin.din: Export New functions. * passwd.cc (read_etc_passwd): Make race safe. (getpwuid_r): New function. (getpwnam_r): New function.
2001-04-09* fhandler.h (class fhandler_socket): Add members and methods toEgor Duda
support secure connections on AF_UNIX sockets. * fhandler_socket.cc (fhandler_socket::set_connect_secret): New method. (fhandler_socket::get_connect_secret): Ditto. (fhandler_socket::create_secret_event): Ditto. (fhandler_socket::close_secret_event): Ditto. (fhandler_socket::check_peer_secret_event): Ditto. (fhandler_socket::fixup_after_fork): Duplicate secret event to child. (fhandler_socket::dup): Copy address family. (fhandler_socket::close): Close secret event. * net.cc (get_inet_addr): Read secret cookie. (cygwin_connect): Check if peer knows secret cookie value. (cygwin_accept): Ditto. Copy address family to newly created socket. (cygwin_bind): Generate and write secret cookie. (wsock_init): Initialize random number generator.
2001-03-20* dtable.cc: Guard against new winsock.h/winsock2.h warnings when mixingChristopher Faylor
winsock*.h and sys/types.h. * fhandler_socket.cc: Ditto. * net.cc: Ditto. * select.cc: Ditto. * exceptions.cc: Remove unneeded define.
2001-03-18Update copyrights.Christopher Faylor
2001-02-08 * autoload.cc: Add LoadDLLinitfunc for iphlpapi.dll.Corinna Vinschen
Add LoadDLLfuncEx statements for GetIfTable@12 and GetIpAddrTable@12. * fhandler_socket.cc (fhandler_socket::ioctl): Move variable definitions to the beginning of the function to allow better debugging. Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU. * net.cc: Include iphlpapi.h. (get_2k_ifconf): Rewritten. Uses IP Helper API now. (get_nt_ifconf): Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU. (get_95_ifconf): Ditto. Renamed from `get_9x_ifconf'. (get_ifconf): Name loopback `lo' instead of `lo0' as in Linux. Add handling for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU. Call `get_95_ifconf' only on Windows 95, `get_nt_ifconf' only on Windows NT < Service Pack 3, `get_2k_ifconf otherwise. * include/asm/socket.h: Add defines for SIOCGIFHWADDR, SIOCGIFMETRIC and SIOCGIFMTU. * include/cygwin/if.h: Add `ifr_hwaddr', `ifr_metric' and `ifr_mtu'. (struct ifreq): Add `ifru_hwaddr'.
2000-10-28Whitespace cleanup.Christopher Faylor
* configure.in: Eliminate subdir stuff. * configure: Regenerate. * include/getopt.h (option): Make name field 'const'.
2000-10-27 * fhandler_socket.cc: New file.Corinna Vinschen
* Makefile.in: Add fhandler_socket.o to dependencies. * fhandler.h: Change comment. * net.cc Move all fhandler_socket methods to fhandler_socket.cc. * winsup.h: Add declaration for `ws2_32_handle'.