summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/include/sys
Commit message (Collapse)AuthorAgeFilesLines
* Switching the Cygwin DLL to LGPLv3+, dropping commercial buyout optioncygwin-2_5_2-releaseCorinna Vinschen2016-06-2337-80/+0
| | | | | | | | | | | | | | Bump GPLv2+ to GPLv3+ for some files, clarify BSD 2-clause. Everything else stays under GPLv3+. New Linking Exception exempts resulting executables from LGPLv3 section 4. Add CONTRIBUTORS file to keep track of licensing. Remove 'Copyright Red Hat Inc' comments. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* cygwin: include sys/types.h in sys/xattr.hYaakov Selkowitz2016-06-031-0/+1
| | | | | | | Using libattr's <xattr/xattr.h> requires consumers to explicitly include <sys/types.h> first, but glibc's header in sys/ already contains the include. Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
* Get rid of some special cases for Cygwin in sys/types.hCorinna Vinschen2016-04-131-3/+1
| | | | | | | | | Remove off_t typedef from cygwin/types.h thus relying on sys/types.h. Introduce winsup/cygwin/machine/_types.h and move some types shared with newlib into it. Get rid of their definition in cygwin/types.h. Add same handling for __key_t/key_t as for the other types. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Fix FIONBIO commentsCorinna Vinschen2016-03-241-1/+2
| | | | | | | FIONBIO is defined in sys/termios.h and asm/socket.h. Align the comments. Remove unused REAL_FIONBIO. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Feature test macros overhaul: dirent.hYaakov Selkowitz2016-03-171-3/+10
| | | | | | | | | | MAXNAMLEN is a BSDism. Use the proper internal macros instead of !_POSIX_SOURCE. telldir and seekdir are XSI, scandir and alphasort are POSIX.1-2008, and scandirat is GNU. Signed-off-by: Yaakov Selkowitz <yselkowi@redhat.com>
* Support profiling of multi-threaded apps.Mark Geisert2016-03-101-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch set modifies Cygwin's profiling support to sample PC values of all an app's threads, not just the main thread. There is no change to how profiling is requested: just compile and link the app with "-pg" as usual. The profiling info is dumped into file gmon.out as always. A new facility enabled via the environment variable GMON_OUT_PREFIX. This facility is intended to match an undocumented Linux glibc feature. Exporting the variable with a non-empty value such as "foo" causes the profiling info to go to a file named foo.$pid instead of the default. With that, both resulting processes of a fork() can have their profiling data captured in separate files. gprof already knows how to accumulate data from multiple files if they all pertain to the same app. There is no change to the normal Cygwin execution paths if profiling is not enabled. And when it is enabled, only the one profiling thread per profiled app is doing more work than it used to. * include/sys/cygwin.h: Add CW_CYGHEAP_PROFTHR_ALL. * cygheap.cc (cygheap_profthr_all): New C-callable function that runs cygheap's threadlist handing each pthread's thread handle in turn to profthr_byhandle(). * external.cc (cygwin_internal): Add case CW_CYGHEAP_PROFTHR_ALL. * gmon.c (_mcleanup): Add support for multiple simultaneous gmon.out* files named via environment variable GMON_OUT_PREFIX. * gmon.h (struct gmonparam): Make state decl volatile. * mcount.c (_MCOUNT_DECL): Change stores into gmonparam.state to use Interlocked operations. Add #include "winsup.h", update commentary. * profil.c (profthr_byhandle): New function abstracting out the updating of profile counters based on a thread handle. (profthr_func): Update to call profthr_byhandle() to sample the main thread then call cygheap_profthr_all() indirectly through cygwin_internal(CW_CYGHEAP_PROFTHR_ALL) to sample all other threads. (profile_off): Zero targthr to indicate profiling was turned off. (profile_on): Fix handle leak on failure path. (profile_child): New callback func to restart profiling in child process after a fork if the parent was being profiled. (profile_ctl): Call pthread_atfork() to set profile_child callback. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Implement POSIX.1e ACL functionsCorinna Vinschen2016-03-081-1/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Makefile.in (DLL_OFILES): Add sec_posixacl.o. (SUBLIBS): Add libacl.a (libacl.a): New rule to create libacl.a. * common.din: Export POSIX ACL functions as well as most libacl.a extensions. * fhandler.h (fhander_base::acl_get): New prototype. (fhander_base::acl_set): Ditto. (fhandler_disk_file::acl_get): Ditto. (fhandler_disk_file::acl_set): Ditto. * include/acl/libacl.h: New file. * include/cygwin/version.h: Bump API minor version. * include/sys/acl.h: Drop including cygwin/acl.h. Accommodate throughout Cygwin. Add POSIX ACL definitions. * sec_acl.cc: Include sec_posixacl.h. Replace ILLEGAL_UID and ILLEGAL_GID with ACL_UNDEFINED_ID where sensible. (__aclcheck): New internal acl check function to be used for Solaris and POSIX ACLs. (aclcheck32): Call __aclcheck. (__aclcalcmask): New function to compute ACL_MASK value. (__aclsort): New internal acl sort function to be used for Solaris and POSIX ACLs. (aclsort32): Call __aclsort. (permtostr): Work directly on provided buffer. (__acltotext): New internal acltotext function to be used for Solaris and POSIX ACLs. (acltotext32): Call __acltotext. (__aclfromtext): New internal aclfromtext function to be used for Solaris and POSIX ACLs. (aclfromtext32): Call __aclfromtext. * sec_posixacl.cc: New file implemeting POSIX ACL functions. * sec_posixacl.h: New internal header. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* cygwin_conv_path: Always preserve trailing backslashes in conversion to ↵Corinna Vinschen2016-02-091-1/+3
| | | | | | | | | | | | | | POSIX paths * include/sys/cygwin.h (CCP_CONVFLAGS_MASK): Define. * mount.h (__CCP_APP_SLASH): Define. * mount.cc (mount_info::conv_to_posix_path): Handle __CCP_APP_SLASH flag. * path.cc (cygwin_conv_path): Use CCP_CONVFLAGS_MASK to evaluate "how" flag values. Always add __CCP_APP_SLASH flag when calling mount_info::conv_to_posix_path. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Convert utmp{x}name to int, return useful value. Define _PATH_UTMPXCorinna Vinschen2016-01-071-1/+1
| | | | | | | | | | | * syscalls.cc (utmpname): Convert to int. Return 0 if strdup worked, -1 otherwise. * include/utmpx.h (_PATH_UTMPX): Define as _PATH_UTMP. (utmpxname): Declare as int function. * include/sys/utmp.h (utmpname): Ditto. * include/cygwin/version.h: Bump API minor version. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Introduce the 'usertemp' filesystem typeJohannes Schindelin2015-12-071-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * mount.cc (mount_info::from_fstab_line): Support mounting the current user's temp folder as /tmp/. This is particularly useful a feature when Cygwin's own files are write-protected. * pathnames.xml: document the new usertemp file system type Detailed explanation: In the context of Windows, there is a per-user directory for temporary files, by default specified via the environment variable %TEMP%. Let's allow to use that directory for our /tmp/ directory. With this patch, we introduce the special filesystem type "usertemp": By specifying none /tmp usertemp binary,posix=0 0 0 in /etc/fstab, the /tmp/ directory gets auto-mounted to the directory specified by the %TEMP% variable. This feature comes handy in particularly in scenarios where the administrator might want to write-protect the entire Cygwin directory yet still needs to allow users to write into the /tmp/ directory. This is the case in the context of Git for Windows, where the Cygwin (MSys2) root directory lives inside C:\Program Files and hence /tmp/ would not be writable otherwise. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
* Move fd_stuff from sys/types.h to sys/select.hCorinna Vinschen2015-12-071-41/+0
| | | | | | | | | | | | | | | | | | * libc/include/sys/types.h: Move definitions of NBBY and howmany to sys/param.h. Move definitions of select(2) macros to sys/select.h. * libc/include/sys/param.h: See above. * libc/include/sys/select.h: Move Cygwin's sys/select.h here. * include/sys/select.h: Move select(2) macros from newlib's sys/types.h here. Rename howmany to _howmany to unclutter namespace. Move file to newlib. * libc/rexex.cc: Add declaration for cygwin_gethostname. * poll.cc: Include sys/param.h and locale select.h. * select.h (cygwin_select): Declare. * uname.cc: Declare cygwin_gethostname. * winsup.h: Drop declarations of cygwin_select and cygwin_gethostname. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Allow cygwin_conv_path(3) and cygpath(1) to emit /proc/cygdrive prefixed pathCorinna Vinschen2015-12-061-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * include/sys/cygwin.h (CCP_PROC_CYGDRIVE): New flag. * mount.cc (mount_info::cygdrive_posix_path): Take flag values rather than just a trailing_slash_p bool. Emit /proc/cygdrive path if CCP_PROC_CYGDRIVE flag is given. (mount_info::conv_to_posix_path): Take flag values rather than just a keep_rel_p bool. Rename _p variables. Print flag value as hex in debug_printf. Call cygdrive_posix_path with flag values. * mount.h (mount_info::cygdrive_posix_path): Accommodate above change in declaration. (mount_info::conv_to_posix_path): Ditto. * fhandler_process.cc (format_process_exename): Accommodate change to mount_info::conv_to_posix_path. * path.cc (cygwin_conv_path): Ditto. * cygpath.cc (absolute_flag): Initialize to CCP_RELATIVE to simplify expressions. (cygdrive_flag): New global flag. (long_options): Add --proc-cygdrive option. (options): Add -U option. (usage): Add description for -U option. (do_sysfolders): Or cygdrive_flag to cygwin_conv_path call. (do_pathconv): Simply or absolute_flag to conv_func. Or cygdrive_flag to conv_func. (do_options): Initalize absolute_flag to CCP_RELATIVE. Initialize new cygdrive_flag. Set absolute_flag to CCP_ABSOLUTE on -a. Set cygdrive_flag to CCP_PROC_CYGDRIVE on -U. * new-features.xml (ov-new2.4): Document cygpath -U option. * utils.xml (cygpath): Ditto. * path.xml (func-cygwin-path): Add CCP_PROC_CYGDRIVE description. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* Try to make sure struct _mcontext is 16-byte alignedJon TURNEY2015-04-231-2/+2
| | | | | | | | | | | | | | | | | | On x86_64, RtlCaptureContext() uses fxsave to save FPU/MMX/SSE state. fxsave requires that the destination address is 16-byte aligned, or it will fault. CONTEXT is already annotated __attribute__ ((aligned (16))), do the same with struct _mcontext. Rearrange ucontext_t so that it's struct _mcontext element is also correctly aligned. * include/cygwin/signal.h (struct __mcontext): 16-byte align. * include/sys/ucontext.h (ucontext_t): Ditto. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
* Provide ucontext to signal handlersJon TURNEY2015-04-231-0/+26
| | | | | | | | | | | | | | Add ucontext.h header, defining ucontext_t and mcontext_t types. Provide sigaction sighandlers with a ucontext_t parameter, containing stack and context information. * include/sys/ucontext.h : New header. * include/ucontext.h : Ditto. * exceptions.cc (call_signal_handler): Provide ucontext_t parameter to signal handler function. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
* Add cygwin_internal() operation to retrieve the EXCEPTION_RECORD from a ↵Jon TURNEY2015-04-231-1/+4
| | | | | | | | | | | siginfo_t * * external.cc (cygwin_internal): Add operation to retrieve a copy of the EXCEPTION_RECORD from a siginfo_t *. * include/sys/cygwin.h (cygwin_getinfo_types): Ditto. * exception.h (cygwin_exception): Add exception_record accessor. Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
* Add CMIN and CTIME definitionsCorinna Vinschen2015-04-231-1/+3
| | | | | | | * include/sys/termios.h: Add CMIN and CTIME. * fhandler_termios.cc (fhandler_termios::tcinit): Use CMIN and CTIME. Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
* * include/sys/socket.h (sockatmark): Add prototype.Corinna Vinschen2015-02-241-1/+2
|
* * cygheap.h (cygheap_pwdgrp): Remove constants NSS_FILES and NSS_DB.Corinna Vinschen2014-11-121-1/+12
| | | | | | | | | | | | | | 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_atexit): Change preceeding comment to reflectCorinna Vinschen2014-11-061-1/+3
| | | | | | | | | | 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).
* * Makefile.in (DLL_OFILES): Add quotactl.o.Corinna Vinschen2014-10-172-2/+244
| | | | | | | | | | | | | | | | | | | * 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.
* * include/sys/file.h: Add extern "C".Corinna Vinschen2014-08-061-0/+9
|
* headers: properly decorate attributesEric Blake2014-08-012-15/+15
| | | | | | | | | | | | | | | | | | 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.
* * external.cc (cygwin_internal): Implement CW_CYGNAME_FROM_WINNAME.Corinna Vinschen2014-05-151-1/+3
| | | | | | Add lengthy comment to explain what we do and why. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_CYGNAME_FROM_WINNAME.
* * cygheap.h (enum cygheap_pwdgrp::cache_t): Remove.Corinna Vinschen2014-03-121-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cygheap_pwdgrp::caching): Convert to bool. (cygheap_pwdgrp::pwd_cache): Add cygserver member. (cygheap_pwdgrp::grp_cache): Ditto. (cygheap_pwdgrp::nss_db_caching): Drop. (cygheap_pwdgrp::nss_db_full_caching): Drop. (cygheap_pwdgrp::nss_cygserver_caching): New method. (cygheap_pwdgrp::nss_disable_cygserver_caching): New method. * cygserver.h (client_request::request_code_t): Add CYGSERVER_REQUEST_PWDGRP. * cygserver_pwdgrp.h: New file. * cygtls.h (struct _local_storage): Remove pwbuf and grbuf members. * grp.cc (pwdgrp::prep_tls_grbuf): Drop. (internal_getgrsid): Handle cygserver caching and rearrange to check the caches first. (internal_getgrnam): Ditto. (internal_getgrgid): Ditto. (gr_ent::enumerate_caches): Handle cygserver cache. * passwd.cc (pwdgrp::prep_tls_pwbuf): Drop. (internal_getpwsid): Handle cygserver caching and rearrange to check the caches first. (internal_getpwnam): Ditto. (internal_getpwuid): Ditto. (pw_ent::enumerate_caches): Handle cygserver cache. * pwdgrp.h (pwdgrp::add_account_from_cygserver): New method declaration. (pwdgrp::fetch_account_from_cygserver): New method declaration. (pwdgrp::prep_tls_pwbuf): Drop declaration. (pwdgrp::prep_tls_grbuf): Drop declaration. (pwdgrp::add_user_from_cygserver): New inline methods. (pwdgrp::add_group_from_cygserver): New inline methods. * tlsoffsets.h: Regenerate. * tlsoffsets64.h: Regenerate. * uinfo.cc (internal_getlogin): Call internal_getgroups if cygserver caching is not available. (cygheap_pwdgrp::init): Initialize pwd_cache.cygserver and grp_cache.cygserver. Set caching to true. (cygheap_pwdgrp::nss_init_line): Drop db_cache handling entirely. (pwdgrp::add_account_from_windows): Drop no caching handling. (client_request_pwdgrp::client_request_pwdgrp): New method. (pwdgrp::fetch_account_from_cygserver): New method. (pwdgrp::add_account_from_cygserver): New method. * fhandler_disk_file.cc (fhandler_base::fstat_helper): Fix formatting. * include/sys/cygwin.h: Ditto.
* * external.cc (cygwin_internal): Add cases for CW_GETNSSSEP,Corinna Vinschen2014-02-221-1/+21
| | | | | | | | | | | | | | | | CW_GETPWSID and CW_GETGRSID. * grp.cc (internal_getgrsid_from_db): New function. * passwd.cc (internal_getpwsid_from_db): New function. (pg_ent::setent): Add special case for call from mkpasswd/mkgroup. * pwdgrp.h (internal_getpwsid_from_db): Declare. (internal_getgrsid_from_db): Declare. (enum nss_enum_t): Move to include/sys/cygwin.h. (class pg_ent): Add comment. * uinfo.cc (pwdgrp::fetch_account_from_windows): Fix typo in comment. Change "UNIX" to "Unix" in domain name. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_GETNSSSEP, CW_GETPWSID and CW_GETGRSID. (enum nss_enum_t): Define here.
* * external.cc (cygwin_internal): Handle new CW_SETENT, CW_GETENT andCorinna Vinschen2014-02-181-2/+8
| | | | | | | | | | | | | | | | | | | | | CW_ENDENT info types. * grp.cc (setgrent_filtered): New function, called from cygwin_internal. (getgrent_filtered): Ditto. (endgrent_filtered): Ditto. * passwd.cc (pg_ent::setent): Set state explicitely to from_cache. (pg_ent::getent): Handle the fact that a DC has no SAM and enumerating local accounts is equivalent to enumerating domain accounts. (setpwent_filtered): New function, called from cygwin_internal. (getpwent_filtered): Ditto. (endpwent_filtered): Ditto. * pwdgrp.h (setpwent_filtered): Declare. (getgrent_filtered): Ditto. (endgrent_filtered): Ditto. (setpwent_filtered): Ditto. (getpwent_filtered): Ditto. (endpwent_filtered): Ditto. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_SETENT, CW_GETENT, and CW_ENDENT.
* * fhandler_disk_file.cc (fhandler_disk_file::fchown): Fix typo inCorinna Vinschen2014-02-061-0/+12
| | | | | | | | | | | comment. * mount.cc (mount_info::from_fstab): Use tmp_pathbuf rather than stack for big local buffer. * net.cc (cygwin_gethostname): Call GetComputerNameExA rather than GetComputerNameA if gethostname failed. * shared.cc (user_info::initialize): Fix formatting. * include/sys/file.h: Define flock and accompanying macros if not already defined in sys/_default_fcntl.h.
* * include/sys/file.h (LOCK_SH): Drop definition in favor of newCorinna Vinschen2014-01-171-20/+0
| | | | | | | | | | | | definitions in newlib. (LOCK_EX): Ditto. (LOCK_NB): Ditto. (LOCK_UN): Ditto. (flock): Ditto. (F_OK): Drop. Already correctly defined in unistd.h. (X_OK): Ditto. (W_OK): Ditto. (R_OK): Ditto.
* * external.cc (fillout_pinfo): Remove nonsensical loop.Christopher Faylor2013-12-181-1/+1
| | | | | | | | | | | | | | | | | | | | * fork.cc (frok::parent): When initializing pinfo for child new PID_NEW flag + actual defined constant rather than raw number. Don't set start_time here. * pinfo.cc (pinfo::thisproc): Use PID_NEW when initializing pinfo. Avoid checking h for NULL multiple times. Don't set start_time here. (pinfo_init): Aways set ppid last. Tweak strace output. (pinfo::init): Handle new PID_NEW flag. Wait for shared memory to contain useful information. Set start_time if PID_NEW. (_onreturn:h): Define as HANDLE rather than HANDLE *. (_onreturn::~onreturn): Accommodate h definition change. (_onreturn::no_close_handle): Rename from no_close_p_handle. Take a pinfo arg and set hProcess to h before zeroing. (winpids::add): Don't open a handle to our own process. Change logic associated with when a handle gets closed. Accommodate no_close_handle changes. (winpids::enum_processes): Simplify process enumeration loop. (winpids::set): Eliminate ill-considered malloc locking. * sigproc.cc (proc_subproc): Always set ppid last.
* Throughout, keep function definitions and declarations in sync withCorinna Vinschen2013-11-251-1/+2
| | | | newlib in terms of C99 "restrict" keyword.
* * include/sys/cygwin.h (struct per_process): Add posix_memalign. ReduceCorinna Vinschen2013-08-141-2/+5
| | | | | | | | | | size of unused2 accordingly. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump. * lib/_cygwin_crt0_common.cc (_cygwin_crt0_common): Initialize u->posix_memalign with address of posix_memalign. * malloc_wrapper.cc (posix_memalign): Call user-provided posix_memalign rather than just returning ENOSYS. * globals.cc (__cygwin_user_data): Initialize posix_memalign member.
* * include/sys/socket.h: Move SHUT_xx definitoins from here...Corinna Vinschen2013-05-311-7/+2
| | | | * include/cygwin/socket.h: ...to here.
* * Merge in cygwin-64bit-branch.Corinna Vinschen2013-04-234-26/+49
|
* * include/sys/queue.h: Delete in favor of more complete newlib file.Corinna Vinschen2013-04-221-512/+0
|
* Adapt to changes in newlib's sys/cdefs.h:Corinna Vinschen2013-04-221-2/+2
| | | | | | * include/sys/sysinfo.h (struct sysinfo): Rename __unused member to __f. * libc/fts.c (__FBSDID): Drop definition. * regex/regexec.c (__unused): Drop definition.
* * include/sys/un.h (UNIX_PATH_MAX): Rename from UNIX_PATH_LEN toCorinna Vinschen2013-03-071-3/+3
| | | | | | | | follow Linux. * fhandler_socket.cc: Change UNIX_PATH_LEN to UNIX_PATH_MAX throughout. (fhandler_socket::recv_internal): Don't return prematurely in case of successful return. For AF_LOCAL sockets, overwrite returned AF_INET name with AF_LOCAL name.
* Throughout, update copyrights to reflect dates which correspond to main-branchChristopher Faylor2013-01-2126-30/+33
| | | | checkins. Regularize copyright format.
* * fhandler.cc (fhandler_base::write): Don't attempt to sparsifyCorinna Vinschen2012-12-141-2/+2
| | | | | | | | | | | | | | | | | an already sparse file. Drop check for FILE_SUPPORTS_SPARSE_FILES flag. Explicitely set FILE_ATTRIBUTE_SPARSE_FILE attribute in cached attributes. (fhandler_base::lseek): Only set did_lseek if sparseness is supported. * fhandler_disk_file.cc (fhandler_disk_file::ftruncate): Don't attempt to sparsify an already sparse file. Explicitely set FILE_ATTRIBUTE_SPARSE_FILE attribute in cached attributes. * mount.cc (oopt): Add "sparse" flag. (fillout_mntent): Ditto. * path.h (enum path_types): Add PATH_SPARSE. (path_conv::support_sparse): New method. (path_conv::fs_flags): Constify. (path_conv::fs_name_len): Ditto. include/sys/mount.h: Replace unused MOUNT_MIXED flag with MOUNT_SPARSE.
* * termios.cc (cfsetspeed): New function.Yaakov Selkowitz2012-11-211-0/+1
| | | | | | | * cygwin.din (cfsetspeed): Export. * posix.sgml (std-bsd): Add cfsetspeed. * include/sys/termios.h (cfsetspeed): Declare. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* * include/sys/termios.h (CBRK): Define as alias of CEOL.Yaakov Selkowitz2012-11-051-0/+9
| | | | | | (CREPRINT): Define as alias of CRPRNT. (CDISCARD): Define as alias of CFLUSH. (TTYDEF_*): Define.
* Fix copyrightCorinna Vinschen2012-10-311-1/+1
|
* * include/sys/param.h: Include stddef.h to define NULL.Corinna Vinschen2012-10-311-4/+3
|
* * include/sys/cygwin.h: Add missing defines for CW_ALLOC_DRIVE_MAP,Corinna Vinschen2012-10-301-0/+3
| | | | CW_MAP_DRIVE_MAP and CW_FREE_DRIVE_MAP.
* * include/sys/wait.h (_wait): Define when building newlib.Corinna Vinschen2012-08-081-1/+5
|
* * include/sys/elf_common.h (R_386_16): Define.Yaakov Selkowitz2012-06-101-0/+4
| | | | | | (R_386_PC16): Define. (R_386_8): Define. (R_386_PC8): Define.
* * include/elf.h: Update from FreeBSD.Yaakov Selkowitz2012-06-065-229/+1239
| | | | | | | | | | | | * include/machine/elf.h: New header, from FreeBSD. * include/sys/elf.h: Ditto. * include/sys/elf32.h: Update from FreeBSD. * include/sys/elf64.h: Ditto. * include/sys/elf_common.h: Ditto. (R_IA64_*): Define Linux-style names as aliases to R_IA_64_*. (R_SH_*): Define, based on sh-4 psABI. (R_390_*): Define, based on s390x psABI. * include/sys/elf_generic.h: Ditto.
* tcgetsid: fix return typeEric Blake2012-02-281-2/+4
| | | | | | | | * include/sys/termios.h (tcgetsid): Fix return type. * termios.cc (tcgetsid): Likewise. * fhandler_termios.cc (fhandler_termios::tcgetsid): Likewise. * fhandler.h (fhandler_base): Likewise. * fhandler.cc (fhandler_base::tcgetsid): Likewise.
* * cygwin.din (scandirat): Export.Yaakov Selkowitz2012-02-221-1/+5
| | | | | | | * posix.sgml (std-gnu): Add scandirat. * syscalls.cc (scandirat): New function. * include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump. * include/sys/dirent.h (scandirat): Declare.
* * include/sys/wait.h: Remove C++ inline functions for `union wait'. For C++Christopher Faylor2012-02-081-16/+10
| | | | | use `void *' as __wait_status_ptr_t instead. This is less type safe but fixes compile error on `wait(NULL)'. Remove extra `;'.
* * include/sys/sysmacros.h: Include sys/types.h.Corinna Vinschen2012-02-081-1/+3
|