summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/path.cc
Commit message (Collapse)AuthorAgeFilesLines
* 2004-10-05 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-10-061-1/+1
| | | | | | | * external.cc (check_ntsec): Do not call wincap.has_security. * path.cc (path_conv::check): Ditto. * security.cc (get_object_attribute): Ditto. (get_file_attribute): Ditto.
* 2004-10-02 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-10-021-1/+0
| | | | | | | | * path.h (enum path_types): Delete PATH_ISDISK. (path_conv::isdisk): Delete method. (path_conv::set_isdisk): Ditto. * path.cc (path_conv::check): Do not call set_isdisk. * uinfo.cc(pwdgrp::load): Do not call pc.isdisk.
* Sergey Ivanov <seriv@parkheights.dyndns.org>Christopher Faylor2004-09-241-4/+4
| | | | | * path.cc (mount_info::read_cygdrive_info_from_registry): Default /cygdrive to binary mode.
* 2004-09-22 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-09-231-7/+5
| | | | | | | * path.cc (normalize_win32_path): Only look for : in second position. Avoid infinite loop with names starting in double dots. (mount_info::conv_to_win32_path): Do not worry about a trailing dot. (hash_path_name): Ditto.
* * exceptions.cc: (ctrl_c_handler): Do nothing while a Cygwin subprocess isChristopher Faylor2004-09-121-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | starting. * child_info.h (init_child_info): Remove pid argument from declaration. * cygheap.h (init_cygheap::pid): New element. * dcrt0.cc (dll_crt0_0): Eliminate handling of now-noexistent cygpid parameter in child_info struct. Set forkee to 'true' rather than cygpid since the pid value was never used. (dll_crt0_1): Ditto. (_dll_crt0): Ditto. * fork.cc (fork_child): Don't wait for sigthread. This is handled in the fork call now. (fork_parent): Remove obsolete pid argument from init_child_info call. Don't do anything special with cygpid when DEBUGGING. (fork): Delay all signals during fork. (fork_init): Don't do anything special when DEBUGGING. * pinfo.cc (set_myself): Remove pid parameter. Use new pid field in cygheap. (pinfo_init): Don't pass pid argument to set_myself. * sigproc.cc (sig_send): Wait for dwProcessId to be non-zero as well as sendsig. (init_child_info): Eliminate handling of pid. (wait_sig): Implement method to temporarily hold off sending signals. * sigproc.h (__SIGHOLD): New enum. (__SIGNOHOLD): Ditto. * spawn.cc (spawn_guts): Remove obsolete pid argument from init_child_info call.
* 2004-09-05 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-09-071-23/+26
| | | | | | | | * cygheap.h (cwdstuff::drive_length): New member. (cwdstuff::get_drive): New method. * path.cc (normalize_win32_path): Simplify by using cwdstuff::get_drive. (mount_info::conv_to_win32_path): Use cwdstuff::get_drive as default for /. (cwdstuff::set): Initialize drive_length.
* Regularize most strace_prints throughout so that %E is always preceded by aChristopher Faylor2004-09-031-1/+1
| | | | comma and elminate most uses of "foo = %s" to "foo %s".
* 2004-06-17 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-06-171-8/+8
| | | | | | | | | | | | | | | * fhandler.cc (fhandler_base::open_9x): Do not check for null name. Move debug_printf to common code line. (fhandler_base::open): Ditto. Initialize upath. Remove second argument of pc.get_nt_native_path. * path.h (path_conv::get_nt_native_path): Remove second argument. * path.cc (path_conv::get_nt_native_path): Ditto. Call str2uni_cat. * security.h (str2buf2uni_cat): Delete declaration. (str2uni_cat): New declaration. * security.cc (str2buf2uni): Get length from sys_mbstowcs call. (str2buf2uni_cat): Delete function. (str2uni_cat): New function. * miscfuncs.cc (sys_mbstowcs): Add debug_printf.
* * path.cc (fchdir): Pass the Posix path to chdir.Corinna Vinschen2004-06-081-1/+1
|
* * spawn.cc (find_exec): Use has_slash to determine if path has a slash ratherChristopher Faylor2004-06-021-5/+5
| | | | than calculating this twice.
* 2004-05-30 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-05-311-24/+25
| | | | | | * path.cc (mount_info::add_item): Make sure native path has drive or UNC form. Call normalize_xxx_path instead of [back]slashify. Remove test for double slashes. Reorganize to always debug_print.
* * path.cc (chdir): Always use the normalized_path as posix_cwd, except if itChristopher Faylor2004-05-281-23/+23
| | | | | | starts with a drive. Also perform whitespace cleanup.
* * cygheap.h (cwdstuff::set): Modify return value and arguments.Christopher Faylor2004-05-151-35/+57
| | | | | | | * path.cc (chdir): Specify PC_POSIX. Do not call SetCurrentDirectory. Set posix_cwd in a way that does not break find.exe. Change call to cwd.set. (cwdstuff::get_initial): Do not call GetCurrentDirectory here. (cwdstuff::set): Call SetCurrentDirectory and GetCurrentDirectory as needed.
* * path.cc (path_conv::check): Don't bail out with error if path is "//".Corinna Vinschen2004-05-121-1/+1
|
* Christopher Faylor <cgf@timesys.com>Christopher Faylor2004-05-071-3/+4
| | | | * path.cc (mount_info::conv_to_posix_path): Add return.
* 2004-05-06 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-05-061-74/+43
| | | | | | | | | * path.cc (path_conv::check): Strip trailing dots and spaces and return error if the final component had only dots and spaces. (normalize_posix_path): Revert 2004-04-30. (chdir): Do not check for trailing spaces. Do not set native_dir to c:\ for virtual devices. Pass only native_dir to cwd.set. (cwdstuff::set): Assume posix_cwd is already normalized.
* * path.cc (normalize_win32_path): Detect components with only dots. Remove aChristopher Faylor2004-05-041-36/+24
| | | | | | | final . if it follows '\\'. (mount_info::conv_to_win32_path): Only backslashify the path when no mount is found. (chdir): Do not look for components with only dots.
* * path.cc (is_unc_share): Remove redundant tests.Christopher Faylor2004-05-041-8/+6
|
* * path.cc (check_sysfile): Don't scan string twice.Corinna Vinschen2004-05-041-2/+3
|
* * fhandler.cc (fhandler_base::open): Call path_conv::get_nt_native_pathCorinna Vinschen2004-04-301-0/+28
| | | | | | | for evaluating NT path. * path.cc (normalize_posix_path): Remove trailing dots and spaces. (path_conv::get_nt_native_path): New function. * path.h (class path_conv): Declare get_nt_native_path method.
* fix commentChristopher Faylor2004-04-201-1/+1
|
* * path.cc (is_unc_share): Rename from slash_unc_prefix_p throughout.Christopher Faylor2004-04-201-40/+25
| | | | | | | | * path.cc (normalize_posix_path): Process all Posix paths and map three or more initial slashes to a single one. Simplify processing following two initial slashes. (normalize_win32_path): Make last argument non-optional and do not check for NULL value.
* * autoload.cc (NtCreateFile): Add.Corinna Vinschen2004-04-161-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * dir.cc (mkdir): Change set_file_attribute call to indicate that NT security isn't used. * fhandler.cc (fhandler_base::open_9x): New method, created from fhandler_base::open. (fhandler_base::open): Rearrange to use NtCreateFile instead of CreateFile. * fhandler.h (enum query_state): Redefine query_null_access to query_stat_control. query_null_access isn't allowed in NtCreateFile. (fhandler_base::open_9x): Declare. * fhandler_disk_file.cc (fhandler_base::fstat_fs): Use query_stat_control first, query_read_control if that fails. (fhandler_disk_file::fchmod): Call enable_restore_privilege before trying to open for query_write_control. Don't fall back to opening for query_read_control. (fhandler_disk_file::fchown): Ditto. (fhandler_disk_file::facl): Only request restore privilege and query access necessary for given cmd. * fhandler_raw.cc (fhandler_dev_raw::open): Call fhandler_base::open instead of opening device here. * ntdll.h (NtCreateFile): Declare. * path.cc (symlink_worker): Change set_file_attribute call to indicate that NT security isn't used. * sec_acl.cc (getacl): Fix bracketing. * sec_helper.cc (enable_restore_privilege): New function. * security.cc (str2buf2uni_cat): New function. (write_sd): Don't request restore permission here. * security.h (set_process_privileges): Drop stale declaration. (str2buf2uni): Declare. (str2buf2uni_cat): Declare. (enable_restore_privilege): Declare. * syscalls.cc (fchown32): Return immediate success on 9x.
* 2004-04-14 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-04-141-1/+1
| | | | | | | | | * path.h (path_conv::set_symlink): Add argument. (path_conv::get_symlink_length): New method. (path_conv::symlink_length): New member. * path.cc (path_conv::check): Pass symlen to set_symlink. * fhandler_disk_file.cc (fhandler_base::fstat_helper): For symlinks set st_size from get_symlink_length.
* * dir.cc (mkdir): Call set_file_attribute with additional handleCorinna Vinschen2004-04-131-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | argument. * fhandler.cc (fhandler_base::fchmod): New method. * fhandler.h: Declare fchmod method in fhandler_base, fhandler_disk_file and fhandler_virtual. * fhandler_disk_file.cc (fhandler_disk_file::fchmod): New method. (fhandler_base::open_fs): Call set_file_attribute with additional handle argument. * fhandler_virtual.cc (fhandler_virtual::fchmod): New method. * path.cc (symlink_worker): Call set_file_attribute with additional handle argument. * security.cc (get_nt_object_security): New function. (get_nt_object_attribute): Call get_nt_object_security. (set_nt_attribute): Add handle argument. Call get_nt_object_security first, read_sd only if that fails. (set_file_attribute): Add handle argument. * security.h (set_file_attribute): Declare with additional handle argument. * syscalls.cc (stat_suffixes): Move to beginning of file. (chown_worker): Call set_file_attribute with additional handle argument. (chmod): Reorganize to call fhandler's fchmod method eventually. (fchmod): Ditto.
* * winsup.h (IMPLEMENT_STATUS_FLAG): New macro to define status flagCorinna Vinschen2004-04-131-1/+0
| | | | | | | | | | | | accessor methods unambiguously. * fhandler.h: Use IMPLEMENT_STATUS_FLAG throughout where possible. * fhandler_termios.cc (fhandler_termios::tcinit): Call corrected accessor for initialized status flag. * mtinfo.h (class mtinfo_drive): Use IMPLEMENT_STATUS_FLAG throughout. * path.cc (fs_info::update): Remove duplicate call to flags(). * path.h (struct fs_info): Use IMPLEMENT_STATUS_FLAG where possible. (path_conv::is_auto_device): Fix spacing. * tty.h (class tty_min): Use IMPLEMENT_STATUS_FLAG throughout.
* 2004-04-12 Pierre Humblet <pierre.humblet@ieee.org>Pierre Humblet2004-04-121-3/+3
| | | | * path.cc (path_conv::check): Fix "tail filling" logic.
* * fhandler.cc (rootdir): Add and use second argument.Corinna Vinschen2004-04-101-2/+1
| | | | | | | * winsup.h (rootdir): Add second argument in declaration. * path.cc (fs_info::update): Modify call to rootdir. * syscalls.cc (check_posix_perm): Ditto. (statfs): Ditto. Move syscall_printf near top.
* * Use new unified status_flag accessor methods from classes fhandler_*,Corinna Vinschen2004-04-101-54/+60
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | tty_min, mtinfo and fs_info thoroughout. * fhandler.h: Redefine all set_close_on_exec methods to take a bool argument. (enum conn_state): Rename from connect_state. (class fhandler_base): Rename some status flags to align with accessor method names. Drop encoded flag entirely. Unify status accessor methods. Const'ify all read accessor methods. (class fhandler_socket): Ditto. (class fhandler_dev_raw): Ditto. * fhandler_disk_file.cc (fhandler_base::fstat_fs): Use fs.fs_is_fat() instead of evaluating FATness of file system here. (fhandler_disk_file::opendir): Drop call to set_encoded(). (fhandler_disk_file::readdir): Use pc.isencoded() directly. * mtinfo.h (class mtinfo_drive): Const'ify all read accessor methods. * path.cc (fsinfo_cnt): Add. (fs_info::update): Accomodate class changes. Evaluate file system name specific flags right here. Add thread safety for reading and writing global fsinfo array. * path.h (enum path_types): Drop values for flags kept in fs already. (struct fs_info): Move status informatin into private struct type status_flags. Add accessor methods. Remove path and file system name string arrays in favor of status bits. (class path_conv): Use new fs_info status information where appropriate. (path_conf::fs_has_ea): Rename from fs_fast_ea. (path_conf::fs_has_acls): New method. (path_conf::root_dir): Remove. (path_conf::volname): Remove. * syscalls (statfs): Evaluate root dir locally. * tty.h (class tty_min): Unify status accessor methods. Const'ify all read accessor methods.
* * path.cc (path_conv::check): Optimize symlink replacements.Christopher Faylor2004-04-101-143/+88
| | | | | | | | | | | | | | | | | | | | * path.cc (normalize_posix_path): Add "tail" argument and set it. Always have a final slash for directories. Pass 3rd argument to normalize_win32_path. (path_conv::check): Pass tail to normalize_posix_path. Set need_directory and remove final slash after that call. Remove last argument to mount_table->conv_to_win32_path(). Remove noop dostail check. Remove fs.update() from inner loop. Improve tail finding search. (normalize_win32_path): Add and set tail argument. (mount_item::build_win32): Avoid calling strcpy. (mount_info::conv_to_win32_path): Remove third argument and simplify because the source is normalized. Keep /proc path in Posix form. Call win32_device_name() only once. (mount_info::conv_to_posix_path): Add and use 3rd argument to normalize_win32_path to avoid calling strlen. (cwdstuff::set): Add 3rd argument to normalize_posix_path and remove final slash if any. * shared_info.h (mount_info::conv_to_win32_path): Remove last argument in declaration.
* * path.cc (fsinfo): Global storage for file system information.Corinna Vinschen2004-04-091-2/+19
| | | | | | (fs_info::update): Store file system information also in fsinfo and short circuit GetVolumeInformation by using alredy stored file system information.
* * path.cc (hash_path_name): Replace hash algorithm with SDBM.Corinna Vinschen2004-04-081-2/+2
|
* * path.cc (path_prefix_p): Optimize test order.Christopher Faylor2004-04-081-3/+3
|
* * path.cc (path_conv::check): Use 'strchr' rather than 'strrchr' to find end ofChristopher Faylor2004-03-261-1/+1
| | | | | | | | | | | | | | | | | string, for efficiency. * include/cygwin/_types.h: New file. * include/sys/lock.h: Ditto. * include/sys/stdio.h: Ditto. * thread.cc: Include sys/lock.h (__cygwin_lock_init): New function. (__cygwin_lock_init_recursive): Ditto. (__cygwin_lock_fini): Ditto. (__cygwin_lock_lock): Ditto. (__cygwin_lock_trylock): Ditto. (__cygwin_lock_unlock): Ditto. (pthread::atforkprepare): Lock file pointer before fork. (pthread::atforkparent): Unlock file pointer after fork. (pthread::atforkchild): Ditto.
* * path.cc (normalize_posix_path): Reorganize to short circuit to DOS pathChristopher Faylor2004-03-251-8/+13
| | | | | | | | | | handling whenever a '\' is detected. * signal.cc (sigaction): Make strace output more informative. * sigproc.cc (pending_signals::add): Just index directly into signal array rather than treating the array as a heap. (pending_signals::del): Ditto. (wait_sig): Don't send signal if we already have a similar signal queued. * sigproc.h (call_signal_handler_now): Remove obsolete declaration.
* update copyright. Minor reformatting.Christopher Faylor2004-03-241-4/+6
|
* * path.cc (conv_path_list): Return error condition.Christopher Faylor2004-02-211-43/+99
| | | | | | | | | | | | | | | | (copy1): New function. (copyenc): New function. (mount_item::fnmunge): Return error condition. Use new functions to copy strings. (mount_item::build_win32): Ditto. (mount_info::conv_to_win32_path): Return error condition. (cygwin_conv_to_posix_path): Return result of path conversion. (cygwin_conv_to_full_posix_path): Ditto. (return_with_errno): New macro. (cygwin_win32_to_posix_path_list): Use new macro to potentially set errno. (cygwin_posix_to_win32_path_list): Ditto. * path.h (mount_item::fnmunge): Add size argument. (mount_item::build_win32): Ditto.
* * Makefile.in (clean): Clean libserver, too.Christopher Faylor2004-02-171-4/+9
| | | | | | | | * fhandler.cc (fhandler_base::~fhandler_base): Remove path_conv cleanup. * syscalls.cc (chroot): Ditto. * path.cc (path_conv::~path_conv): Define new destructor. (conv_path_list_buf_size): Remove explicit path_conv cleanup. * path.h (path_conv::~path_conv): Declare new destructor.
* * path.cc (mount_item::build_win32): Backslashify paths in non-managed case.Christopher Faylor2003-12-261-1/+4
|
* * exceptions.cc (set_signal_mask): Redefine to not pass by address. ReportChristopher Faylor2003-12-231-38/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | calculated mask in debugging output. * sigproc.h (set_signal_mask): Reflect above change in declaration. * path.cc (mount_item::build_win32): Take path apart before feeding it to fnmunge. Throughout, change use of _reent_winsup()-> to _my_tls.locals. instead. Throughout, remove obsolete MT_SAFE/_CYG_THREAD_FAILSAFE considerations. Througout, add cygtls.h include. * Makefile.in (DLL_OFILES): Add cygtls.o. Add some more objects to the -fomit-frame-pointer list. * acconfig.h: Remove obsolete settings. * config.h.in: Ditto. * bsdlib.cc: Add cygtls.h include. * configure.in: Remove --enable-extra-threadsafe-checking. * configure: Regenerate. * cygtls.h (_local_storage): New struct renamed from _winsup_t (sic). (_threadinfo:local_clib): Add new field. (_threadinfo::locals): Ditto. (_threadinfo::init_thread): Accept second _reent * argument. (_threadinfo::call): Define as regparm. (CYGTLS_PADSIZE): Remove unnecessary slop. (_getreent): Define as a macro. * thread.h: Remove _CYG_THREAD_FAILSAFE and MT_SAFE stuff. (_winsup_t): Move to cygtls.h. (ResourceLocks::ResourceLocks): Eliminate empty constructor. (MTinterface::reents): Eliminate. (MTinterface::thread_self_key): Eliminate. (MTinterface::MTinterface): Eliminate. * dcrt0.cc: Include stdio.h for _impure_ptr initialization. (do_global_ctors): Remove run_ctors_p (sic) considerations. Don't call atexit here. (__main): Initialize destructors for user here. (dll_crt0_1): Accept a dummy argument. Don't call init_thread here. Don't set _impure_ptr here. Call do_global_ctors after more things have been initialized. (_dll_crt0): Define zeros buffer as max of needed size of CYGTLS_PADSIZE so that it can be used for two purposes while minimizing stack usage. Initialize _impure_ptr specifically, for speed. Call dll_crt0_1 with buffer argument. (cygwin_dll_init): Call dll_crt0_1 with dummy argument. * dtable.cc (dtable::find_unused_handle): Remove call to AssertResourceOwner. * exceptions.cc: Move _threadinfo stuff to new file. * cygtls.cc: New file. * gentls_offsets: Accommodate increasing complexity of cygtls.h. * hires.h (hires_base::~hires_base): Remove. * init.cc (dll_entry): Remove setting of reents. * thread.cc: Remove syslog.h include. (__getreent): Simplify to use _my_tls. (_reent_winsup): Delete. (AssertResourceOwner): Delete. (MTinterface::Init): Remove setting of _clib and _winsup, with all that entails. (MTinterface::fixup_after_fork): Ditto. (pthread::thread_init_wrapper): Ditto. Also remove call to set_tls_self_pointer. (pthread::set_tls_self_pointer): Eliminate. (pthread::get_tls_self_pointer): Just return _my_tls.tid; (__reent_t::init_clib): Eliminate. * tlsoffsets.h: Regenerate.
* * winsup.h (access_worker): Declare with added fhandler_base parameter.Christopher Faylor2003-12-151-1/+1
| | | | | | | | | * syscalls.cc (access_worker): Accommodate extra fhandler_base argument. Use it instead of stat_worker to determine stat information, when appropriate. * fhandler.cc (fhandler_base::device_access_denied): Pass fhandler pointer to access_worker so that it can use the proper method for determining stat information. * fhandler_disk_file.cc (fhandler_disk_file::opendir): Ditto.
* Change use of BOOL, TRUE, FALSE to bool, true, false, as appropriate,Christopher Faylor2003-12-071-16/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | throughout. * tty.cc (tty::common_init): Remove call to SetKernelObjectSecurity and edit some comments. * cygheap.h (init_cygheap::ctty): Add new element. * devices.in (device::parse): Remove special handling for /dev/tty. * devices.cc: Regenerate. * dtable.cc (build_fh_pc): Don't reset /dev/tty device. Let the device opener do that. * fhandler_termios.cc (tty_min::set_ctty): Redefine to _pinfo class. * fhandler_tty.cc (fhandler_tty_common::set_close_on_exec): Avoid setting noninherit flag for ctty. * tty.h: Move BOOLs to bools. (tty_min::set_ctty): Redeclare to _pinfo class. * pinfo.cc (_pinfo::set_ctty): Define new function based on tty_min::set_ctty. Change first argument from tty number to tty_min class. * pinfo.h (_pinfo::set_ctty): Declare. * fhandler_console.cc (fhandler_console::get_tty_stuff): Reflect move of set_ctty to _pinfo class. * fhandler_tty.cc (fhandler_tty_slave::open): Treat FH_TTY specially. Use saved cygheap value if it exists. Otherwise convert to real device and save on first time open. (fhandler_tty_common::dup): Potentially set controlling tty if duping a slave tty. * syscalls.cc (setsid): Close controlling tty in cygheap. * tty.cc: Change some BOOLs to bools.
* * path.cc (slash_unc_prefix_p): Allow '.' as a valid character after '\\' in aChristopher Faylor2003-12-051-1/+1
| | | | UNC path.
* Eliminate use of sigframe and sigthread throughout.Christopher Faylor2003-11-281-3/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (DLL_OFILES): Add sigfe.o. Remove reliance on cygwin.def from cygwin0.dll dependency since dependence on sigfe.o implies that. Generate def file on the fly using 'gendef'. * configure.in: Don't auto-generate cygwin.def. * configure: Regenerate. * cygwin.din: Add SIGFE stuff where appropriate. * dcrt0.cc (dll_crt0_1): Initialize cygwin tls early in process startup. Set _main_tls to address of the main thread's cygwin tls. * debug.h: Remove now unneeded WFSO and WFMO declarations. * exceptions.cc (_last_thread): Define. (set_thread_state_for_signals): New function. (reset_thread_exception_for_signals): Ditto. (init_thread_for_signals): Ditto. (delete_thread_for_signals): Ditto. (capture_thread_for_signals): Ditto. (handle_exceptions): Set return address explicitly for exceptions prior to calling sig_send. (interrupt_on_return): Eliminate. (setup_handler): Add preliminary implementation for dealing with thread-specific signals by querying _main_tls. (signal_exit): Use cygthread::main_thread_id instead of mainthread.id. (call_signal_handler_now): For now, just handle the main thread. * fork.cc (vfork): Save and restore main _my_tls. * gendef: New file. Generates def file and sigfe.s file. * gentls_offsets: New file. Generates offsets for perl to use in sigfe.s. * how-signals-work.txt: Mention that info is obsolete. * init.cc (dll_entry): Initialize cygwin tls storage here. * miscfuncs.cc (low_priority_sleep): Make a C function for easier calling from asm. * perthread.h (vfork_save::tls): New element. * signal.cc (nanosleep): Replace previous use of sigframe.call_signal_handler_now with straight call to call_signal_handler_now. (abort): Ditto. * syscalls.cc (readv): Ditto. * termios.cc (tcsetattr): Ditto. * wait.cc (wait4): Ditto. * sigproc.cc (sig_dispatch_pending): Ditto. (sig_send): Ditto. * sigproc.h: Declare call_signal_handler_now. * thread.cc (pthread::thread_init_wrapper): Initialize cygwin tls. Remove obsolete and unworking signal stuff. * thread.h (verifyable_object::sigs): Eliminate. (verifyable_object::sigmask): Eliminate. (verifyable_object::sigtodo): Eliminate. (verifyable_object::exit): Make attribute noreturn. (verifyable_object::thread_init_wrapper): Ditto. (pthread_null::exit): Ditto. * winbase.h (__stackbase): Always define. * winsup.h (low_priority_sleep): Declare as a "C" function. * include/cygwin/version.h: Bump API version to reflect sigwait export. * include/sys/queue.h: Protect SLIST_ENTRY from previous declaration. * signal.cc (sigwait): Implement. * select.cc (fhandler_base::ready_for_read): Add debugging output. * devices.h: Define more device pointers via their storage. * devices.in: Don't parse things like /dev/inet/tcp, as they really have no meaning. * devices.cc: Regenerate. * gendevices: Set proper protection for output file. * cygtls.h: New file. * gendef: New file. * gentls_offsets: New file. * tlsoffsets.h: New file. Autogenerated. * config/i386/longjmp.c: Remove. File subsumed by gendef output. * config/i386/makefrag: Remove obsolete file. * fhandler.cc: Remove spurious access_worker declaration. * spawn.cc (spawnve): Make debugging output more accurate. * cygwin-gperf: Remove. * devices.cc: Remove.
* * dir.cc (mkdir): Use local security_descriptor. CallCorinna Vinschen2003-11-261-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | set_security_attribute appropriately. * external.cc (cygwin_internal): Ditto. * fhandler.cc (fhandler_base::open): Ditto. * fhandler_socket.cc (fhandler_socket::bind): Ditto. * path.cc (symlink_worker): Ditto. * sec_acl.cc (setacl): Ditto. Call read_sd appropriately. (getace): Ditto. * sec_helper.cc (security_descriptor::malloc): New method. (security_descriptor::realloc): New method. (security_descriptor::free): New method. * security.cc (read_sd): Get security_descriptor as parameter instead of PSECURITY_DESCRIPTOR and a size. Drop unnecessary parameter check. Allocate the security_descriptor buffer according to size returned by a call to GetFileSecurity. Return buffer size on success. (write_sd): Get security_descriptor as parameter instead of PSECURITY_DESCRIPTOR and a size. (get_nt_attribute): Use local security_descriptor. (get_nt_object_attribute): Ditto in case of type == SE_REGISTRY_KEY. Allocate security_descriptor buffer according to size returned by a call to RegGetKeySecurity. (alloc_sd): Make static. Get security_descriptor as parameter instead of PSECURITY_DESCRIPTOR and a size. Drop unnecessary parameter check. (set_security_attribute): Get security_descriptor as parameter instead of PSECURITY_DESCRIPTOR and a size. (set_nt_attribute): Use local security_descriptor. (check_file_access): Ditto. * security.h: Add class security_descriptor. (read_sd): Change declaration to get security_descriptor as parameter instead of PSECURITY_DESCRIPTOR and a size. (write_sd): Ditto. (set_security_attribute): Ditto. (alloc_sd): Remove declaration. * thread.cc (semaphore::semaphore): Use local security_descriptor. Call set_security_attribute appropriately.
* 2003-11-11 Robert Collins <rbtcollins@hotmail.com>Robert Collins2003-11-141-45/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ron Parker <rdparker@butlermfg.com> * bsdlib.cc: Update throughout to use CYG_MAX_PATH rather than MAX_PATH. * cygheap.h: Ditto. * dcrt0.cc: Ditto. * delqueue.cc: Ditto. * dlfcn.cc: Ditto. * dll_init.cc: Ditto. * dll_init.h: Ditto. * dtable.cc: Ditto. * environ.cc: Ditto. * environ.h: Ditto. * exceptions.cc: Ditto. * external.cc: Ditto. * fhandler_disk_file.cc: Ditto. * fhandler_proc.cc: Ditto. * fhandler_process.cc: Ditto. * fhandler_raw.cc: Ditto. * fhandler_registry.cc: Ditto. * fhandler_socket.cc: Ditto. * fhandler_virtual.cc: Ditto. * miscfuncs.cc: Ditto. * mmap.cc: Ditto. * netdb.cc: Ditto. * path.cc: Ditto. * path.h: Ditto. * pinfo.cc: Ditto. * pinfo.h: Ditto. * pthread.cc: Ditto. * registry.cc: Ditto. * shared.cc: Ditto. * shared_info.h: Ditto. * smallprint.c: Ditto. * spawn.cc: Ditto. * strace.cc: Ditto. * syscalls.cc: Ditto. * thread.h: Ditto. * uinfo.cc: Ditto. * winsup.h: Ditto. * include/limits.h: Ditto. * include/cygwin/config.h: Ditto. * include/sys/param.h: Ditto.
* * path.cc (dot_special_chars): New global variable.Christopher Faylor2003-10-291-2/+15
| | | | | | (special_name): Make files ending in "." special. (fnunmunge): Allow encoded ".". (mount_item::fnmunge): Handle trailing ".".
* * path.cc (normalize_posix_path): Test runs of more than twoCorinna Vinschen2003-10-251-1/+8
| | | | dots for being a run of only dots. Let it pass if not.
* * path.cc (win32_device_name): Fix comment.Corinna Vinschen2003-10-241-2/+3
|
* * path.cc (win32_device_name): Only fill out destination buffer when it'sChristopher Faylor2003-10-021-2/+4
| | | | really a device.