summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin
Commit message (Collapse)AuthorAgeFilesLines
...
* * net.cc (if_freenameindex): Don't catch a SEGV from free to failCorinna Vinschen2014-08-212-3/+5
| | | | loudly on double free.
* * dir.cc (rmdir): Don't skip deleting fh in the ENOTEMPTY case.Corinna Vinschen2014-08-212-4/+5
|
* * tls_pbuf.h (tmp_pathbuf::tmp_pathbuf): Convert to inline method.Corinna Vinschen2014-08-203-13/+18
| | | | | | (tmp_pathbuf::~tmp_pathbuf): Ditto. * tls_pbuf.cc (tmp_pathbuf::tmp_pathbuf): Remove here. (tmp_pathbuf::~tmp_pathbuf): Ditto.
* * dir.cc (dirfd): Per POSIX, return EINVAL on invalid directory stream.Corinna Vinschen2014-08-193-3/+13
| | | | | | (telldir): Per POSIX, return -1 and set errno to EBADF, rather than just returning 0, on invalid directory stream. * signal.cc (sigwaitinfo): Return -1, not EFAULT, when SEGV was catched.
* * fhandler.h (enum conn_state): Add "connect_credxchg" state.Corinna Vinschen2014-08-193-9/+31
| | | | | | | | | | (class fhandler_socket): Grant another bit to connect_state flag. * fhandler_socket.cc (fhandler_socket::af_local_connect): Rearrange variable definition. Set connect_state to connect_credxchg. (fhandler_socket::af_local_accept): Ditto. (fhandler_socket::recv_internal): Accept connect_credxchg on connection oriented AF_LOCAL sockets as well to allow the credential exchange. Extend comment to explain.
* * autoload.cc: Replace WNet[...]A with WNet[...]W imports.Corinna Vinschen2014-08-194-50/+78
| | | | | | | * dcrt0.cc (initial_env): Drop strlwr calls. Call strcasestr instead. * fhandler_netdrive.cc: Throughout, convert to calling WNet UNICODE functions. Use tmp_pathbuf rather than alloca. Replace call to strlwr with call to RtlDowncaseUnicodeString.
* * fhandler.h (fhandler_serial::is_tty): Reinstantiate.Corinna Vinschen2014-08-192-0/+6
|
* * miscfuncs.cc (strlwr): Rename from cygwin_strlwr. Drop __stdcallCorinna Vinschen2014-08-183-11/+14
| | | | | | | decoration. (strupr): Rename from cygwin_strupr. Drop __stdcall decoration. * string.h (strlwr): Remove override macro. Simply declare. (strupr): Ditto.
* *** empty log message ***Corinna Vinschen2014-08-181-0/+7
|
* * dtable.cc (dtable::init_std_file_from_handle): Mention that consoleCorinna Vinschen2014-08-185-20/+55
| | | | | | | | | | | | | | | handles are kernel objects since Windows 8. * fhandler.h (enum conn_state): Add "listener" state. (class fhandler_socket): Drop listener status flag. (fhandler_socket::lseek): Return -1 and errno ESPIPE. (fhandler_serial::lseek): Ditto. * fhandler_socket.cc (fhandler_socket::listen): Set connect_state to listener. Add comment. (fhandler_socket::accept4): Explicitely check if the socket is listening and fail with EINVAL, if not. Explain why we have to do that. (fhandler_socket::recv_internal): Explicitely check if the socket is connected if it's a stream socket. Explain why we have to do that. (fhandler_socket::getpeereid): Drop now redundant test.
* * winsup.h (_GNU_SOURCE): Define. Explain why.Corinna Vinschen2014-08-154-22/+55
| | | | | * configure.ac: Convert to new AC_INIT style. * configure: Regenerate.
* * cygerrno.h (seterrno): Define as (always) inline function.Corinna Vinschen2014-08-153-11/+14
| | | | * errno.cc (seterrno): Remove.
* * dll_init.sgml: Remove.Corinna Vinschen2014-08-145-62/+7
| | | | | | * dtable.sgml: Move into ../doc/misc-funcs.xml. * external.sgml: Ditto. * stackdump.sgml: Ditto.
* * security.sgml: Move to ../doc dir and rename to logon-funcs.xml.Corinna Vinschen2014-08-142-45/+4
|
* * path.sgml: Move to ../doc dir and rename to path.xml.Corinna Vinschen2014-08-143-1735/+6
| | | | * posix.sgml: Move to ../doc dir and rename to posix.xml.
* * dlmalloc.c: Remove unused file.Corinna Vinschen2014-08-144-5199/+2516
| | | | | * dlmalloc.h: Ditto. * malloc.cc: Update to Doug Lea's malloc version 2.8.6.
* * include/cygwin/version.h (CYGWIN_VERSION_DLL_MINOR): Bump to 33.Corinna Vinschen2014-08-134-9/+38
| | | | (CYGWIN_VERSION_API_MINOR): Bump to reflect intermediate 1.7.32 release.
* * cpuid.h: Add missing copyright header. Fix formatting. Use uint32_tCorinna Vinschen2014-08-115-93/+204
| | | | | | | | | | | | | instead of unsigned throughout. Change functions to static inline and always inline. (cpuid): Add parameter to set ecx, allowing to request extended CPUID info. * fhandler_proc.cc (format_proc_cpuinfo): Use uint32_t instead of unsigned throughout. Add fake decimal places to MHz info. Handle more feature flags. * fhandler_random.cc (fhandler_dev_random::write): Allow up to 4K input to add entropy. * syscalls.cc: Drop including cpuid.h.
* * common.din (__cxa_finalize): Export.Yaakov Selkowitz2014-08-075-5/+14
| | | | | | | * dcrt0.cc (cygwin_atexit): Use d->handle with __cxa_atexit. * dll_init.cc (dll_list::detach): Use d->handle with __cxa_finalize. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Use 274 for __cxa_finalize as well.
* * include/sys/file.h: Add extern "C".Corinna Vinschen2014-08-062-0/+13
|
* * common.din (__cxa_atexit): Export.Corinna Vinschen2014-08-043-1/+8
| | | | * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump to 274.
* * uinfo.cc (pwdgrp::fetch_account_from_windows): Drop "plus_prepended"Corinna Vinschen2014-08-042-65/+75
| | | | | | | as naming style. Drop enum name_style_t, use a boolean "fully_qualified_name" value instead. Rework function to drop "plus_prepended" handling througout and default to "name only" style as replacement.
* headers: properly decorate attributesEric Blake2014-08-016-27/+36
| | | | | | | | | | | | | | | | | | As pointed out here: https://cygwin.com/ml/cygwin/2014-07/msg00371.html any use of __attribute__ in a header that can be included by a user should be namespace-safe, by decorating the attribute arguments with __ (while gcc does a lousy job at documenting it, ALL attributes have a __ counterpart, precisely so that public headers can use attributes without risk of collision with macros belonging to user namespace). * include/pthread.h: Decorate attribute names with __, for namespace safety. * include/cygwin/core_dump.h: Likewise. * include/cygwin/cygwin_dll.h: Likewise. * include/sys/cygwin.h: Likewise. * include/sys/strace.h: Likewise.
* * uinfo.cc (pwdgrp::fetch_account_from_windows): Fix comment.Corinna Vinschen2014-07-302-8/+11
|
* * cygheap.h (class cygheap_domain_info): Remove lowest_tdo_posix_offset.Corinna Vinschen2014-07-295-20/+49
| | | | | | | | | | | | | | | | * ldap.cc (cyg_ldap::fetch_posix_offset_for_domain): Return UINT32_MAX in case of error. * security.h (PRIMARY_POSIX_OFFSET): Define. (NOACCESS_POSIX_OFFSET): Define. (UNUSABLE_POSIX_OFFSET): Define. * uinfo.cc (cygheap_domain_info::init): Drop initializing lowest_tdo_posix_offset. (pwdgrp::fetch_account_from_file): Set PosixOffset to either UNUSABLE_POSIX_OFFSET or NOACCESS_POSIX_OFFSET in case we don't get a sensible offset from AD. Explain why. Drop setting ch lowest_tdo_posix_offset. (pwdgrp::fetch_account_from_windows): Replace constant 0x100000 with PRIMARY_POSIX_OFFSET throughout.
* * fhandler_socket.cc (fhandler_socket::send_internal): Fix value ofCorinna Vinschen2014-07-242-2/+12
| | | | | out_len when tweaking the last buffer so out_len is correct in a subsequent if expression.
* * thread.cc (pthread::init_mainthread): Initialize thread mutex toCorinna Vinschen2014-07-212-0/+9
| | | | type PTHREAD_MUTEX_RECURSIVE, just as for any other thread.
* bump to 32Corinna Vinschen2014-07-212-1/+5
|
* * uinfo.cc: Fix typo in comment.Corinna Vinschen2014-07-212-1/+5
|
* *** empty log message ***Corinna Vinschen2014-07-181-1/+1
|
* .Christopher Faylor2014-07-161-0/+4
|
* *** empty log message ***Corinna Vinschen2014-07-161-0/+5
|
* * thread.cc (pthread::create): Handle stackaddr as upper bound address.Corinna Vinschen2014-07-163-16/+56
| | | | | | | | | | | | | | | | | Add comment. (pthread_attr_setstack): Store upper bound address in stackaddr. Explain why. (pthread_attr_getstack): Handle stackaddr as upper bound address. Add comment. (pthread_attr_setstackaddr): Add comment. (pthread_attr_getstackaddr): Add comment. (pthread_attr_getstacksize): Return default stacksize if stacksize has not been set by the application, just as on Linux. Add comment. (pthread_getattr_np): Store upper bound address in stackaddr. Explain why. * include/pthread.h: Remove outdated comment. (pthread_attr_getstackaddr): Mark as deprecated, as on Linux. (pthread_attr_setstackaddr): Ditto.
* *** empty log message ***Corinna Vinschen2014-07-162-8/+39
|
* * sigproc.cc (sigproc_init): Set aside more buffer space for signal pipes.Christopher Faylor2014-07-152-2/+21
| | | | | (sig_send): Retry WriteFiles which fail when there is no error but packbytes have not been sent.
* * sigproc.cc (send_sig): Don't report an error if WriteFile succeeds.Christopher Faylor2014-07-152-1/+5
|
* Fix typoCorinna Vinschen2014-07-151-1/+1
|
* * sigproc.cc (send_sig): Fix bad format in diagnostic output.Christopher Faylor2014-07-143-3/+398
|
* * uinfo.cc (cygheap_domain_info::init): Correctly setCorinna Vinschen2014-07-142-17/+22
| | | | | | lowest_tdo_posix_offset to UNIX_POSIX_OFFSET. (fetch_posix_offset): Redesign to fake a POSIX offset in all cases where we can't fetch a non-0 POSIX offset from our primary domain.
* * thread.cc (pthread_mutex::pthread_mutex): Change default typeCorinna Vinschen2014-07-143-5/+17
| | | | | | | | | | | to PTHREAD_MUTEX_NORMAL. (pthread_mutex::unlock): Return EPERM if the mutex has no owner and the mutex type is PTHREAD_MUTEX_ERRORCHECK, as on Linux. (pthread_mutexattr::pthread_mutexattr): Ditto. (pthread_mutex_unlock): Do not fail if mutex is a normal mutex initializer. * include/pthread.h (PTHREAD_MUTEX_INITIALIZER): Redefine as PTHREAD_NORMAL_MUTEX_INITIALIZER_NP.
* * thread.cc (pthread::create): Use PTHREAD_DEFAULT_STACKSIZE stacksizeCorinna Vinschen2014-07-092-13/+23
| | | | | | | | | | | | if attr.stacksize is 0. (pthread_attr::pthread_attr): Initialize stacksize to 0 to align more closely to Linux. (pthread_attr_getstack): Fix incorrect stackaddr computation. Return stackaddr just like pthread_attr_getstackaddr. Remove slightly off comment. (pthread_attr_getstackaddr): Remove slightly off comment. (pthread_getattr_np): Return stackaddr and stacksize based on the full allocated stackarea.
* * exceptions.cc (exception::myfault_handle): Rephrase comment.Corinna Vinschen2014-07-092-1/+8
|
* * exceptions.cc (exception::myfault_handle): Fix typo in comment.Corinna Vinschen2014-07-092-1/+5
|
* * exceptions.cc (exception::myfault_handle): Disable handlingCorinna Vinschen2014-07-073-0/+10
| | | | STATUS_STACK_OVERFLOW. Explain why.
* * fhandler_socket.cc (fhandler_socket::send_internal): Improve loop toCorinna Vinschen2014-07-072-16/+49
| | | | | | write streams in chunks of wmem() bytes to raise performance when writing small buffers. Rename variables and add comments to help understanding the code in years to come.
* * passwd.cc (pg_ent::enumerate_ad): Revert to simply skipping a domainCorinna Vinschen2014-07-072-16/+10
| | | | if opening the connection to the domain fails.
* * libc/minires.c (minires_dprintf): Change "Minires" to "Resolv" toCorinna Vinschen2014-07-072-2/+13
| | | | | | differ from external minres lib. (res_nquerydomain): Fix off-by-one in domain concatenation. Add debug output.
* * fhandler_disk_file.cc (fhandler_disk_file::fstatvfs): Add debugCorinna Vinschen2014-07-032-0/+9
| | | | output.
* * errno.cc (errmap): Fix order of SERVICE_REQUEST_TIMEOUT.Corinna Vinschen2014-06-252-1/+5
|
* * errno.cc (errmap): Handle Windows error codes ERROR_CANCELLED,Corinna Vinschen2014-06-253-2/+17
| | | | | | | | ERROR_CONNECTION_REFUSED, ERROR_DEV_NOT_EXIST, ERROR_DS_GENERIC_ERROR, ERROR_NOT_ENOUGH_QUOTA, ERROR_SERVICE_REQUEST_TIMEOUT, ERROR_TIMEOUT, ERROR_UNEXP_NET_ERR. * ldap.cc (cyg_ldap::map_ldaperr_to_errno): Drop explicit LDAP_TIMEOUT handling.