summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin
Commit message (Collapse)AuthorAgeFilesLines
...
* * cygheap.cc (init_cygheap::find_tls): Add comment.Corinna Vinschen2014-11-286-57/+88
| | | | | | | | | | | | | | | | * cygtls.cc (well_known_dlls): Rephrase comment. (bloda_detect): New function. (_cygtls::call2): Call init_thread and bloda_detect for non-pthread threads only. (_cygtls::remove): Move remove_tls and remove_wq calls up to run first. * miscfuncs.cc (struct pthread_wrapper_arg): Rename from struct thread_wrapper_arg. (pthread_wrapper): Rename from thread_wrapper and drop "static". Fix comment. Drop call to _cygtls::remove. Call api_fatal rather than ExitThread. Explain why. * miscfuncs.h (pthread_wrapper): Declare pthread_wrapper. * thread.cc (pthread::exit): Add a FIXME comment. Call _cygtls::remove before calling ExitThread.
* * mount.cc (mount_info::init): Take bool argument and allow toCorinna Vinschen2014-11-275-11/+40
| | | | | | | | | | | | | initialize mount table in two steps, system and user, depending on bool value. * mount.h (class mount_info): Align declaration of init function to above change. * shared.cc (user_info::initialize): Initialize mount table in two steps to allow internal_getpwsid to create valid POSIX paths from DOS paths given in AD. Add comments. * uinfo.cc (cygheap_pwdgrp::get_home): Allow DOS paths in NSS_SCHEME_FREEATTR attributes. (cygheap_pwdgrp::get_shell): Ditto.
* * cygheap.cc (init_cygheap::find_tls): Allow to keep loop going afterCorinna Vinschen2014-11-272-19/+33
| | | | | access to threadlist[ix] faulted. In case of an exception, remove threadlist[ix] from threadlist only. Add comment.
* * Makefile.in (install): Add install-ldif target.Corinna Vinschen2014-11-267-185/+913
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (install-ldif): New target to install cygwin.ldif. * cygheap.h (class cygheap_pwdgrp): Rename pfx_t to nss_pfx_t. Add PFX to enum value. Add nss_scheme_method enum and nss_scheme_t structure. Add home_scheme, shell_scheme and gecos_scheme members. (NSS_SCHEME_MAX): Define. (cygheap_pwdgrp::get_home): Declare. (cygheap_pwdgrp::get_shell): Declare. (cygheap_pwdgrp::get_gecos): Declare. * cygwin.ldif: New file. * ldap.cc (std_user_attr): New array, just defining the standard attributes. (group_attr): Add cygwinUnixGid. (user_attr): Convert to macro pointing to cygheap->pg.ldap_user_attr. (cygheap_pwdgrp::init_ldap_user_attr): New method. (cyg_ldap::fetch_ad_account): Call cygheap_pwdgrp::init_ldap_user_attr if user_attr initialization is required. Fix comment. (cyg_ldap::get_string_attribute): Implement taking attribute name as argument. * ldap.h: Drop unused macros. (cyg_ldap::get_gecos): Remove. (cyg_ldap::get_home): Remove. (cyg_ldap::get_shell): Remove. (cyg_ldap::get_string_attribute): Declare name argument variant public. * uinfo.cc (cygheap_user::ontherange): Fix indentation. (cygheap_pwdgrp::init): Initialize new home_scheme, shell_scheme and gecos_scheme members. Align comment. (NSS_NCMP): Define comparison macro. (NSS_CMP): Ditto. (cygheap_pwdgrp::nss_init_line): Use aforementioned macros throughout. Fix comment handling. Add db_home, db_shell and db_gecos handling. (fetch_from_description): New function to fetch XML-style attributes from (description) string. (fetch_from_path): New function to evaluate path string with wildcards. (cygheap_pwdgrp::get_home): New methods to fetch pw_dir value. (cygheap_pwdgrp::get_shell): Ditto for pw_shell. (cygheap_pwdgrp::get_gecos): Ditto for pw_gecos. (colon_to_semicolon): Move up. (pwdgrp::fetch_account_from_windows): Convert home, shell, gecos variables to char*. Drop statement breaking extended group info. Fetch home, shell and gecos values using new methods. Use fetch_from_description calls to fetch UNIX id and primary groups from SAM comment field. Accommodate uxid being a char* now. Accommodate the fact that extended info is malloc'ed, rather then alloca'ed. Create linebuf content as multibyte string. Create line buffer by just calling cstrdup.
* * include/fcntl.h: Move all open flags (except O_NDELAY) to newlib'sCorinna Vinschen2014-11-252-15/+7
| | | | sys/_default_fcntl.h.
* * binmode.c (cygwin_premain0): Don't use underscore'd variants of theCorinna Vinschen2014-11-253-6/+12
| | | | | open flags. * textmode.c (cygwin_premain0): Ditto.
* * init.cc (dll_entry): Revert previous patch. This requires anotherCorinna Vinschen2014-11-214-4/+23
| | | | | | | | | solution. * miscfuncs.cc (thread_wrapper): Ditto. * sigproc.cc (exit_thread): Disable sending a signal for synchronization with process exit. Explain why. Keep code in for later inspection, should the problem show up again. (sig_send): Use "tls", rather than "tid" as name for _cygtls arg.
* * init.cc (dll_entry): Call _my_tls.remove with INFINITE wait periodCorinna Vinschen2014-11-203-2/+8
| | | | | to avoid SEGVs and subsequent hangs in _cygtls::find_tls. * miscfuncs.cc (thread_wrapper): Ditto.
* * net.cc (fdsock): Change default values for socket buffers on 32 bitCorinna Vinschen2014-11-202-2/+14
| | | | to fix performance on 10Gb networks.
* * uinfo.cc (pwdgrp::fetch_account_from_windows): Allow fetching ofCorinna Vinschen2014-11-172-4/+27
| | | | | | NT SERVICE accounts by name. Always prepend domain to NT SERVICE accounts. Add U-domain\username string to pw_gecos for predefined builtin accounts as well.
* * fhandler_termios.cc (fhandler_termios::line_edit): Fix fatal typo inCorinna Vinschen2014-11-142-2/+7
| | | | bytes_read pointer checks.
* * fhandler.h (fhandler_termios::line_edit): Add parameter to returnCorinna Vinschen2014-11-134-23/+54
| | | | | | | | | | | | | | written bytes. * fhandler_termios.cc (fhandler_termios::tcinit): Fix formatting. (fhandler_termios::line_edit): Return bytes actually written. Write in 32 byte chunks in non-canonical mode to reduce number of WriteFile calls. Don't just eat unwritten bytes in case of an error condition. Especially, don't report them back to the caller as written. * fhandler_tty.cc (fhandler_pty_slave::read): Disable code reducing the number of bytes read from the pipe to vmin. Add comment. (fhandler_pty_master::write): Convert ret to ssize_t type. Just call line_edit once, not in a loop once for each byte. Return bytes written as returned by line_edit.
* * include/cygwin/version.h (CYGWIN_VERSION_DLL_MINOR): Bump to 34.Corinna Vinschen2014-11-134-23/+37
| | | | | * new-features.xml (ov-new1.7.34): Add new section. (ov-new1.7.33): Reflect intermediate 1.7.33 release.
* * cygheap.h (cygheap_pwdgrp): Remove constants NSS_FILES and NSS_DB.Corinna Vinschen2014-11-126-13/+48
| | | | | | | | | | | | | | Use NSS_SRC_FILES and NSS_SRC_DB throughout instead. (cygheap_pwdgrp::nss_pwd_src): New inline method. (cygheap_pwdgrp::nss_grp_src): Ditto. * external.cc (cygwin_internal): Add CW_GETNSS_PWD_SRC and CW_GETNSS_GRP_SRC cases. * uinfo.cc: Use NSS_SRC_FILES and NSS_SRC_DB throughout. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_GETNSS_PWD_SRC and CW_GETNSS_GRP_SRC. (NSS_SRC_FILES): Define. (NSS_SRC_DB): Define.
* * dcrt0.cc (cygwin__cxa_atexit): Fetch correct DSO handle valueCorinna Vinschen2014-11-072-6/+13
| | | | by searching dll list. Explain why.
* * dcrt0.cc (cygwin_atexit): Change preceeding comment to reflectCorinna Vinschen2014-11-066-11/+46
| | | | | | | | | | API version numbers. * external.cc (cygwin_internal): disable setting cxx_malloc on 64 bit. Add CW_FIXED_ATEXIT case. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_FIXED_ATEXIT. * lib/atexit.c (atexit): Test running Cygwin version by checking return value of cygwin_internal (CW_FIXED_ATEXIT).
* * lib/atexit.c (atexit): Check for being linked into the executable.Corinna Vinschen2014-11-053-1/+30
| | | | | If so, call __cxa_atexit with NULL DSO handle. Explain why. * lib/dso_handle.c: New file providing fallback __dso_handle.
* *** empty log message ***Corinna Vinschen2014-11-051-0/+8
|
* * Makefile.in (NEW_FUNCTIONS): Add atexit to be not exported.Corinna Vinschen2014-11-054-17/+51
| | | | | | | | * lib/atexit.c (atexit): New, statically linkable version of atexit. * dcrt0.cc (cygwin_atexit): Add comment to mark this function as old entry point. Indiscriminately check for DSO of function pointer for all functions, if checking for DSO of return address fails on x86_64. Change comment accordingly.
* * Makefile.in (NEW_FUNCTIONS): Define target-independent. Add targetCorinna Vinschen2014-11-052-3/+60
| | | | | dependent stuff afterwards. Globally define timezone and all xdr symbols as non-exported from libcygwin.a.
* * cygheap.cc: Fix formatting.Corinna Vinschen2014-11-032-2/+7
|
* * uinfo.cc (cygheap_user::ontherange): Don't mention /etc/passwd.Corinna Vinschen2014-10-302-1/+5
|
* Fix copyright dateCorinna Vinschen2014-10-291-1/+1
|
* * cygheap.cc (init_cygheap::init_installation_root): Create content ofCorinna Vinschen2014-10-292-3/+18
| | | | installation_dir as non-prefixed path, if possible.
* * common.din (__cxa_atexit): Define as cygwin__cxa_atexit.Corinna Vinschen2014-10-294-1/+28
| | | | * dcrt0.cc (cygwin__cxa_atexit): New function. Explain what we do.
* * globals.cc (dos_file_warning): Set to false by default.Corinna Vinschen2014-10-284-4/+13
| | | | | | * path.cc (warn_msdos): Make static. Drop test for dos_file_warning. (path_conv::check): Check for dos_file_warning here to avoid a function call in the default case.
* * dcrt0.cc (cygwin_atexit): Add workaround for broken atexit callsCorinna Vinschen2014-10-273-0/+38
| | | | in __gcc_register_frame of DLLs built with gcc-4.8.3-3.
* * dlfcn.cc (dlopen): Drop patch accommodating SetDllDiretory fromCorinna Vinschen2014-10-272-28/+6
| | | | 2014-10-14.
* * cygheap.cc (cygheap_fixup_in_child): Drop call to set_dll_dir.Corinna Vinschen2014-10-276-53/+87
| | | | | | | | | | | | | | | | | (init_cygheap::init_installation_root): Set installation_dir_len. (setup_cygheap): Drop call to set_dll_dir. * cygheap.h (struct init_cygheap): Add installation_dir_len member. (init_cygheap::set_dll_dir): Remove. * environ.cc (win_env::add_cache): Use stpcpy for speed. (posify_maybe): Use tmp_pathbuf buffer instead of stack. (raise_envblock): New function to resize Windows environment block. (build_env): Fix indentation. Call raise_envblock function. Check if $PATH exists and is non-empty. If not, add PATH variable with Cygwin installation directory as content to Windows environment. Explain why. * uinfo.cc (cygheap_pwdgrp::_nss_init): Fill UNICODE_STRING members on the fly. Drop call to RtlInitUnicodeString. (pwdgrp::check_file): Ditto.
* *** empty log message ***Corinna Vinschen2014-10-271-0/+3
|
* * fhandler_socket.cc (fhandler_socket::af_local_connect): DropCorinna Vinschen2014-10-264-23/+21
| | | | | | | | | setting connect_state to connect_credxchg. (fhandler_socket::af_local_accept): Ditto. (fhandler_socket::recv_internal): Drop ill-advised connect_state check. Add comment so as not to repeat the exercise. * fhandler.h (enum conn_state): Drop now unneeded connect_credxchg state.
* *** empty log message ***Corinna Vinschen2014-10-241-1/+1
|
* * fhandler_proc.cc (format_proc_cygdrive): Fix symlink path if cygdriveCorinna Vinschen2014-10-242-1/+7
| | | | is "/".
* * gendef (sigdelayed): 64 bit only: Fix seh_pushreg statements inCorinna Vinschen2014-10-242-3/+7
| | | | prologue.
* * gendef (sigdelayed): 64 bit only: Push CPU flags before aligningCorinna Vinschen2014-10-242-5/+14
| | | | stack to avoid changing flag values.
* *** empty log message ***Corinna Vinschen2014-10-221-0/+3
|
* * common.din (stime): Export.Yaakov Selkowitz2014-10-226-1/+22
| | | | | | * times.cc (stime): New function. * include/cygwin/time.h (stime): Declare. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* *** empty log message ***Corinna Vinschen2014-10-221-1/+1
|
* *** empty log message ***Corinna Vinschen2014-10-221-3/+8
|
* *** empty log message ***Corinna Vinschen2014-10-221-9/+45
|
* * sec_auth.cc (get_user_groups): Remove experimental exception handlerCorinna Vinschen2014-10-212-16/+12
| | | | | added 2014-09-05. (get_user_local_groups): Ditto.
* Fix typoCorinna Vinschen2014-10-201-1/+1
|
* * fhandler_serial.cc: Revert debug code accidentally checked in onCorinna Vinschen2014-10-202-1/+6
| | | | 2014-08-18.
* *** empty log message ***Corinna Vinschen2014-10-201-0/+2
|
* * path.cc (symlink_info::check): Set error from status code if openingCorinna Vinschen2014-10-202-1/+12
| | | | the parent directory failed, but keep special case for root dirs.
* * cygheap.cc (cygheap_fixup_in_child): Call set_dll_dir.Corinna Vinschen2014-10-177-31/+63
| | | | | | | | | | | | | | | | | (init_cygheap::init_installation_root): Just memmove contents of installation_root instead of calling GetModuleFileNameW again. Copy installation_root to installation_dir before stripping of "bin" dir. Don't call SetDllDirectory here. Explain what we do. (setup_cygheap): New function taking over initial cygheap setup from memory_init. Additionally call set_dll_dir. * cygheap.h (struct init_cygheap): Add installation_dir member. (init_cygheap::set_dll_dir): Define. (setup_cygheap): Declare. * dcrt0.cc: Throughout drop parameter from memory_init call. (dll_crt0_0): Call setup_cygheap prior to memory_init. * dlfcn.cc (dlopen): Change comment to point to the right function. * shared.cc (memory_init): Drop parameter. Drop cygheap setup. * shared_info.h (memory_init): Change declaration accordingly.
* fix typoCorinna Vinschen2014-10-171-1/+1
|
* * cygtls.h (__try): Define __l_endtry as block-local label in 32 bitCorinna Vinschen2014-10-172-1/+7
| | | | case as well.
* *** empty log message ***Corinna Vinschen2014-10-171-0/+8
|
* * Makefile.in (DLL_OFILES): Add quotactl.o.Corinna Vinschen2014-10-178-8/+660
| | | | | | | | | | | | | | | | | | | * common.din (quotactl): Export. * ntdll.h: Define FILE_FS_CONTROL_INFORMATION::FileSystemControlFlags flag values. (struct _FILE_FS_CONTROL_INFORMATION): Define. (struct _FILE_GET_QUOTA_INFORMATION): Define. (typedef struct _FILE_QUOTA_INFORMATION): Define. (NtQueryObject): Use PVOID rather than VOID*. (NtQueryVolumeInformationFile): Ditto. (NtQueryQuotaInformationFile): Declare. (NtSetQuotaInformationFile): Declare. (NtSetVolumeInformationFile): Declare. * quotactl.cc: New file implementing quotactl(). * include/sys/mount.h (BLOCK_SIZE): Define. (BLOCK_SIZE_BITS): Define. * include/sys/quota.h: New header. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.