summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin
Commit message (Collapse)AuthorAgeFilesLines
* * newsym: Reenable removal of tmp directory. Just use ar to generate archiveChristopher Faylor2003-07-073-6/+10
| | | | | index. * Makefile.in: Don't send ranlib to newsym.
* * newsym: Create objects that are closer to those created by dlltool so as notChristopher Faylor2003-07-073-6/+24
| | | | | | to confuse --export-all-symbols. * rmsym: Be a little more accepting of object filenames now that dlltool can create different format files.
* * newsym: Oops. Revert below change.Christopher Faylor2003-07-072-1/+5
|
* * newsym: Use correct prefix for generating imports.Christopher Faylor2003-07-063-2/+8
| | | | | * pinfo.cc (_pinfo::commune_send): Don't wait forever for a response from another process.
* white spaceChristopher Faylor2003-07-061-1/+1
|
* * syscalls.cc (gethostid): Set thread affinity so that results are predictable.Christopher Faylor2003-07-062-6/+19
|
* * mmap.cc (list::match): Add parameters to return valid address andCorinna Vinschen2003-07-052-25/+54
| | | | | | | | | | length back to munmap(). Evaluate intersection between given area and mapped area and return it, if any. (mmap64): On regular files, don't allow mappings beginning beyond EOF. Return with errno set to ENXIO instead. (munmap): Rewrite SUSv3 conformant. Check if given memory area is valid. Unmap all maps inside given memory area. Don't return error if no mapping has been unmapped.
* * fhandler.h (fhandler_socket::get_connect_state): New method toCorinna Vinschen2003-07-054-5/+32
| | | | | | | | | | return socket connection state. * fhandler_socket.cc (dup): Copy socket connect state to new file handle. * net.cc (cygwin_rcmd): Mark file handles of sockets returned by rcmd() as CONNECTED state. (cygwin_rexec): Similarly for rexec(). (socketpair): Mark both ends of a new socket pair as CONNECTED.
* fix typoChristopher Faylor2003-07-041-1/+1
|
* * mmap.cc (fhandler_disk_file::mmap): Fix address test.Corinna Vinschen2003-07-042-1/+5
|
* * path.cc (fillout_mntent): Change "posix" to "managed".Christopher Faylor2003-07-042-1/+5
|
* * fhandler.h (FH_ENC): New enum.Christopher Faylor2003-07-045-33/+150
| | | | | | | | | | | | | | | | | | | | (fhandler_base::get_encoded): New function. (fhandler_base::set_encoded): Ditto. * fhandler_disk_file.cc (fhandler_disk_file::opendir): Set encoded flag in fhandler, as appropriate. (fhandler_disk_file::readdir): Unmunge filename as appropriate based on new encoding flag. * path.cc (normalize_posix_path): Don't punt on files with colons. (special_char): New function. (mount_item::fnmunge): Ditto. (fnunmunge): Ditto. (special_name): Ditto. (mount_item::build_win32): Avoid drive considerations when file is encoded. (mount_info::conv_to_win32_path): Handle encoded filenames. (mount_info::conv_to_posix_path): Ditto. (fillout_mntent): Add posix string when directory is encoded. * path.h (fnunmunge): Declare. (path_conv::is_encoded): Declare.
* * fhandler_tty.cc (fhandler_tty_slave::open): Conditionalize a little more ofChristopher Faylor2003-07-032-5/+11
| | | | the cygserver stuff so that ttys actually work.
* * mmap.cc (mmap64): Allow MAP_FIXED with pagesize granularity (4K).Corinna Vinschen2003-07-032-7/+58
| | | | | | | If a non-zero addr is given, align it to the next lower 64K boundary. (fhandler_disk_file::mmap): If a non-zero address is given, try mapping using the given address first. If it fails and flags is not MAP_FIXED, try again with NULL address.
* * thread.cc: Remove _MT_SAFE conditional.Christopher Faylor2003-07-022-3/+4
|
* fix typoChristopher Faylor2003-07-022-2/+2
|
* * configure.in: Fix --enable-server option.Christopher Faylor2003-07-023-11/+9
|
* * Makefile.in: Remove cygserver stuff.Christopher Faylor2003-07-0217-142/+122
| | | | | | | | | | | | | | | | | | | | | | * acconfig.h: Add USE_CYGSERVER define. * config.h.in: Regenerate. * configure.in: Add --enable-server setting. * configure: Regenerate. * fhandler_tty.cc (fhandler_tty_slave::open): Conditionalize compilation of cygserver stuff. * fork.cc (fork_child): Ditto. * shm.cc: Ditto. * tty.cc (tty::common_init): Ditto. * dcrt0.cc: Use bool rather than BOOL for CYGWIN environment variable definitions. * environ.cc: Ditto. * ntea.cc: Ditto. * security.cc: Ditto. * security.h: Ditto. * syscalls.cc (check_posix_perm): Remove externs that were already declared in a header. * winsup.h: Ditto. Declare _MT_SAFE here. Delete it someday since cygwin should always be _MT_SAFE.
* * cygheap.h (enum impersonation): New enum.Corinna Vinschen2003-06-3010-113/+158
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (cygheap_user::token): Delete. (cygheap_user::impersonated): Delete. (cygheap_user::external_token): New member. (cygheap_user::internal_token): New member. (cygheap_user::impersonation_state): New member. (cygheap_user::issetuid): Modify. (cygheap_user::token): New method. (cygheap_user::deimpersonate): New method. (cygheap_user::reimpersonate): New method. (cygheap_user::has_impersonation_tokens): New method. (cygheap_user::close_impersonation_tokens): New method. * dtable.cc (dtable::vfork_child_dup): Use new cygheap_user methods. * fhandler_socket.cc (fhandler_socket::dup): Ditto. * fork.cc (fork_child): Ditto. (fork_parent): Ditto. * grp.cc (internal_getgroups): Ditto. * security.cc (verify_token): Ditto. (check_file_access): Ditto. (cygwin_set_impersonation_token): Detect conflicts. Set user.external_token. * spawn.cc (spawn_guts): Use new cygheap_user methods. * syscalls.cc (seteuid32): Rearrange to use the two tokens in cygheap_user. (setegid32): Use new cygheap_user methods. * uinfo.cc: (internal_getlogin): Ditto.
* * Makefile.in: Use INSTALL_PROGRAM to install the cygwin DLL.Christopher Faylor2003-06-252-1/+5
|
* * thread.cc (MTinterface::fixup_after_fork): Fix thread list after fork.Thomas Pfaff2003-06-243-10/+72
| | | | | | | | | | | | | | | | | | (pthread::threads): Instantiate. (pthread::pthread): Initialize running and suspendend. Initialize next with NULL. Add thread to thread list if it is not the null_pthread. (pthread::~pthread): Remove thread from thread list if it is not the null_pthread. (pthread::postcreate): Set running flag. (pthread::exit): Reset running flag. (pthread::cancel): Try to cancel thread only if still running. (pthread::_fixup_after_fork): Implement. (pthread::detach): Check if thread is still running before detach. * thread.h (pthread::running): New member. (pthread::next): Ditto. (pthread::fixup_after_fork): New static method. (pthread::threads): New static method. (pthread::_fixup_after_fork): New method.
* * pinfo.cc (_pinfo::commune_send): Don't attempt to communicate with a pureChristopher Faylor2003-06-212-1/+6
| | | | windows process.
* 2003-06-18 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2003-06-193-6/+32
| | | | | | * autoload.cc (GetNetworkParams): Add. * net.cc (getdomainname): Call GetNetworkParams and read the DhcpDomain registry value if warranted.
* * path.cc (mount): Do more strict checking on posix path arguments.Christopher Faylor2003-06-172-2/+15
|
* Throughout, remove "include <errno.h>" from files which already includeChristopher Faylor2003-06-1679-87/+65
| | | | | | | | | | | | | | | | | | | cygerrno.h. * include/cygwin/config.h (__DYNAMIC_REENT__): Define. * include/cygwin/version.h: Bump API minor version. * cygwin.din: Export __getreent * cygerrno.h: Include errno.h. Fix places where _impure_ptr is used directly to store the errno value. * debug.cc (__set_errno): Ditto. * errno.cc: Remove _RRENT_ONLY define to get errno.cc compiled. * signal.cc: Rename _reent_clib to _REENT throughout. * thread.h (reent_clib): Remove prototype. * thread.cc (reent_clib): Rename reent_clib to __getreent. Return _impure_ptr until MTinterface is initialized. (reent_winsup): Fix a possible SEGV when _r == NULL. Return NULL instead. * MTinterface::fixup_after_fork: Switch reent back to _impure_ptr to keep signal handling running when fork is called from a thread other than the mainthread.
* * thread.cc (pthread_attr_init): Revert change from 2003-06-11Thomas Pfaff2003-06-122-4/+12
| | | | | | | to return 0 if attribute is already initialized back to EBUSY. (pthread_condattr_init): Ditto. (pthread_rwlockattr_init): Ditto. (pthread_mutexattr_init): Ditto.
* * exceptions.cc (ctrl_c_handler): Don't send a signal onCorinna Vinschen2003-06-122-0/+11
| | | | CTRL_SHUTDOWN_EVENT. Add a comment to rationalize the patch.
* * thread.cc (pthread_attr_init): Return 0 if attribute is already initialized.Thomas Pfaff2003-06-112-10/+23
| | | | | | | Fix return code if out of memory. (pthread_condattr_init): Ditto. (pthread_rwlockattr_init): Ditto. (pthread_mutexattr_init): Return 0 if attribute is already initialized.
* * spawn.cc (spawn_guts): Call CreateProcess while impersonated,Corinna Vinschen2003-06-094-20/+50
| | | | | | | | | | when the real {u,g}ids and the groups are original. Move RevertToSelf and ImpersonateLoggedOnUser to the main line. * uinfo.cc (uinfo_init): Reorganize. If CreateProcess was called while impersonated, preserve the uids and gids and call ImpersonateLoggedOnUser. Preserve the uids and gids on Win9X. * exceptions.cc (error_start_init): Quote the pgm in the command.
* fix typoChristopher Faylor2003-06-071-1/+1
|
* * poll.cc: Define FD_SETSIZE to ridiculously large number so that there will beChristopher Faylor2003-06-072-0/+6
| | | | no artificially large limits.
* * fhandler_tty.cc (fhandler_tty_slave::close): Free the console when last ttyChristopher Faylor2003-06-072-1/+7
| | | | closes.
* * fhandler_socket.cc (fhandler_socket::connect): Change errorThomas Pfaff2003-06-072-6/+14
| | | | | handling for nonblocking connects to return EALREADY when connect is called more than once for the same socket.
* * cygwin.din: Add vsyslog.Corinna Vinschen2003-06-066-7/+28
| | | | | | | | | | * fhandler.cc (fhandler_base::write): Only make file sparse if the seeked area is >= 128K. * syslog.cc (vsyslog): New function, overtaking functionality from syslog. (syslog): Just call vsyslog. * include/cygwin/version.h: Bump API minor. * include/sys/syslog.h: Add vsyslog declaration.
* * cygthread.cc (cygthread::terminate_thread): Change system_printf toChristopher Faylor2003-06-052-1/+6
| | | | debug_printf.
* * shared.cc (shared_info::heap_chunk_size): Be really defensive about makingChristopher Faylor2003-06-052-0/+7
| | | | sure that heap_chunk is set.
* * path.cc (conv_path_list): Use correct value when calculating length to avoidChristopher Faylor2003-06-042-1/+6
| | | | a potential SEGV.
* 2003-06-03 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2003-06-042-25/+17
| | | | | | | * fhandler_disk_file.cc (fhandler_disk_file::fstat): Mark the pc as non-executable if the file cannot be opened for read. Retry query open only if errno is EACCES. Never change the mode, even if it is 000 when query open() fails.
* * configure.in: Allow any i?86 variant.Christopher Faylor2003-06-041-0/+5
| | | | * configure: Regenerate.
* * configure.in: Allow any i?86 variant.Christopher Faylor2003-06-032-2/+2
| | | | * configure: Regenerate.
* * fhandler_socket.cc (connect_thread): Remove.Corinna Vinschen2003-06-033-55/+77
| | | | | | | | | (accept_thread): Remove. (fhandler_socket::connect): Remove all special blocking handling. (fhandler_socket::accept): Ditto. * net.cc (cygwin_connect): Make blocking sockets temporarily non-blocking and call cygwin_select on them to be interruptible. (cygwin_accept): Ditto.
* * spawn.cc (spawn_guts): Don't hang around if the parent doesn't exist.Christopher Faylor2003-06-032-2/+6
|
* * cygthread.h (cygthread::terminate_thread): Mark private.Christopher Faylor2003-06-023-5/+16
| | | | | * cygthread.cc (cygthread::terminate_thread): Deallocate free_range thread stuff.
* * fhandler_socket.cc (fhandler_socket::accept): Rename `signalled'Corinna Vinschen2003-06-022-2/+7
| | | | to `interrupted' as used in fhandler_socket::connect.
* * fhandler_socket.cc (fhandler_socket::connect): Simplify previousCorinna Vinschen2003-06-022-28/+16
| | | | | patch. (fhandler_socket::accept): Ditto.
* * fhandler_socket.cc: Include cygthread.h.Corinna Vinschen2003-06-022-110/+71
| | | | | | | | | (class sock_event): Remove. (thread_connect): New function. (thread_accept): Ditto. (fhandler_socket::connect): Use cygthread instead of socket event handling for blocking sockets. (fhandler_socket::accept): Ditto.
* * fhandler.cc (fhandler_base::write): Correct minor printf formatting styleChristopher Faylor2003-06-022-1/+6
| | | | glitch.
* 2003-06-01 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2003-06-012-12/+17
| | | | | * fhandler_disk_file.cc (fhandler_disk_file::fstat_by_name): Assume an existing directory is a root if FindFirstFile fails.
* * path.cc (mount_info::conv_to_win32_path): gcc warning about chroot_ok wasChristopher Faylor2003-05-302-3/+9
| | | | actually valid. Fix it.
* * cygheap.cc (init_cheap): Temporarily remove inline that newer gcc's haveChristopher Faylor2003-05-304-15/+22
| | | | | | problems with. * path.cc (path_conv::check): Rework has_acls logic slightly. Uncouple exec tests away from filesystem tests.