]> sourceware.org Git - newlib-cygwin.git/log
newlib-cygwin.git
10 years ago * include/glob.h: Fix invalid use of 'restrict' error.
Corinna Vinschen [Thu, 28 Nov 2013 10:00:01 +0000 (10:00 +0000)]
* include/glob.h: Fix invalid use of 'restrict' error.

10 years ago2013-11-27 Sebastian Huber <sebastian.huber@embedded-brains.de>
Joel Sherrill [Wed, 27 Nov 2013 14:53:59 +0000 (14:53 +0000)]
2013-11-27  Sebastian Huber  <sebastian.huber@embedded-brains.de>

* libc/sys/rtems/cpusetalloc.c: New file.
* libc/sys/rtems/cpusetfree.c: Likewise.
* libc/sys/rtems/Makefile.am (lib_a_SOURCES): Add new files.
* libc/sys/rtems/Makefile.in: Regenerate.
* libc/sys/rtems/sys/cpuset.h: Delete #if 0 block.  Include
<stddef.h> for size_t.
(_NCPUBITS): Avoid NBBY and assume 8 bits per char.
(__cpuset_mask): Use int instead of size_t parameter for Linux
compatibility.
(__cpuset_index): Likewise.
(__cpuset_alloc): Declare.
(__cpuset_free): Likewise.
(CPU_ALLOC_SIZE): Likewise.
(CPU_ALLOC): Define.
(CPU_FREE): Likewise.
(CPU_ZERO_S): Likewise.
(CPU_FILL_S): Likewise.
(CPU_SET_S): Likewise.
(CPU_CLR_S): Likewise.
(CPU_ISSET_S): Likewise.
(CPU_COUNT_S): Likewise.
(CPU_AND_S): Likewise.
(CPU_OR_S): Likewise.
(CPU_XOR_S): Likewise.
(CPU_NAND_S): Likewise.
(CPU_EQUAL_S): Likewise.
(CPU_ZERO): Use CPU_ZERO_S().
(CPU_FILL): Use CPU_FILL_S().
(CPU_SET): Use CPU_SET_S().
(CPU_CLR): Use CPU_CLR_S().
(CPU_ISSET): Use CPU_ISSET_S().
(CPU_COUNT): Use CPU_COUNT_S().
(CPU_AND): Use CPU_AND_S().
(CPU_OR): Use CPU_OR_S().
(CPU_XOR): Use CPU_XOR_S().
(CPU_NAND): Use CPU_NAND_S().
(CPU_EQUAL): Use CPU_EQUAL_S().
(CPU_CMP): Delete superfluous const qualifier.
(CPU_EMPTY): Likewise.

10 years ago * syscalls.cc (try_to_bin): Enhance debug output in case reopen fails.
Corinna Vinschen [Wed, 27 Nov 2013 14:48:27 +0000 (14:48 +0000)]
* syscalls.cc (try_to_bin): Enhance debug output in case reopen fails.

10 years ago * syscalls.cc (try_to_bin): Drop fh_dup, reuse tmp_fh instead.
Corinna Vinschen [Wed, 27 Nov 2013 14:30:36 +0000 (14:30 +0000)]
* syscalls.cc (try_to_bin): Drop fh_dup, reuse tmp_fh instead.

10 years ago * syscalls.cc (try_to_bin): Take additional parameter to get file open
Corinna Vinschen [Wed, 27 Nov 2013 14:27:34 +0000 (14:27 +0000)]
* syscalls.cc (try_to_bin): Take additional parameter to get file open
flags.  If the file to move to the bin has been opened casesensitive,
reopen it caseinsensitive.  Explain why.  Revert the default name of
the Vista-and-later recycler to mixed case for readability.
(unlink_nt): Call try_to_bin with file open flags as evaluated.

10 years ago * libc/machine/mips/setjmp.S: Fix definition of macro FPR_LAYOUT
Corinna Vinschen [Wed, 27 Nov 2013 12:45:56 +0000 (12:45 +0000)]
* libc/machine/mips/setjmp.S: Fix definition of macro FPR_LAYOUT
for ABI == N32.

10 years ago2013-11-26 Matheus Almeida <Matheus.Almeida@imgtec.com>
Jeff Johnston [Tue, 26 Nov 2013 19:58:19 +0000 (19:58 +0000)]
2013-11-26  Matheus Almeida  <Matheus.Almeida@imgtec.com>

        * libc/include/machine/setjmp.h: Add support for __mips_fpr being
        64 and treat it the same as if __mips64 is set.
        * libc/machine/mips/setjmp.S: Ditto, plus add checks for _MIPS_SIM
        being _ABIN32 and _ABI64.

10 years ago * nlsfuncs.cc (wcscoll): Add "__restrict" to definition.
Corinna Vinschen [Tue, 26 Nov 2013 17:27:25 +0000 (17:27 +0000)]
* nlsfuncs.cc (wcscoll): Add "__restrict" to definition.
(wcsxfrm): Ditto.

10 years agoCorrect for missing entries for wchar.h changes and white space changes
Joel Sherrill [Tue, 26 Nov 2013 17:27:08 +0000 (17:27 +0000)]
Correct for missing entries for wchar.h changes and white space changes

10 years ago2013-11-26 Julio Gutierrez <jgutleyva@gmail.com>
Joel Sherrill [Tue, 26 Nov 2013 17:21:01 +0000 (17:21 +0000)]
2013-11-26  Julio Gutierrez <jgutleyva@gmail.com>

*libc/include/wchar.h: Add restrict keyword.
*libc/stdio/fgetws.c (fgetws): ditto.
*libc/stdio/fputws.c (fputws): ditto.
*libc/stdio/fwprintf.c (fwprintf): ditto.
*libc/stdio/fwscanf.c (fwscanf): ditto.
*libc/stdio/swprintf.c (swprintf): ditto.
*libc/stdio/swscanf.c (swscanf): ditto.
*libc/stdio/vfwprintf.c (vfwprintf): ditto.
*libc/stdio/vfwscanf.c (vfwscanf): ditto.
*libc/stdio/vswprintf.c (vswprintf): ditto.
*libc/stdio/vswscanf.c (vswscanf): ditto.
*libc/stdio/vwprintf.c (vwprintf): ditto.
*libc/stdio/vwscanf.c (vwscanf): ditto.
*libc/stdio/wprintf.c (wprintf): ditto.
*libc/stdio/wscanf.c (wscanf): ditto.
*libc/stdlib/mbrlen.c (mbrlen): ditto.
*libc/stdlib/mbrtowc.c (mbrtowc): ditto.
*libc/stdlib/mbsnrtowcs.c (mbsnrtowcs): ditto.
*libc/stdlib/mbsrtowcs.c (mbsrtowcs): ditto.
*libc/stdlib/wcrtomb.c (wcrtomb): ditto.
*libc/stdlib/wcsnrtombs.c (wcsnrtombs): ditto.
*libc/stdlib/wcsrtombs.c (wcsrtombs): ditto.
*libc/stdlib/wcstod.c (wcstod): ditto.
*libc/stdlib/wcstol.c (wcstol): ditto.
*libc/stdlib/wcstold.c (wcstold): ditto.
*libc/stdlib/wcstoll.c (wcstoll): ditto.
*libc/stdlib/wcstoul.c (wcstoul): ditto.
*libc/stdlib/wcstoull.c (cstoull): ditto.
*libc/string/wcpcpy.c (wcpcpy): ditto.
*libc/string/wcpncpy.c (wcpncpy): ditto.
*libc/string/wcscat.c (wcscat): ditto.
*libc/string/wcscpy.c (wcscpy): ditto.
*libc/string/wcsncat.c (wcsncat): ditto.
*libc/string/wcsncpy.c (wcsncpy): ditto.
*libc/string/wcsstr.c (wcsstr): ditto.
*libc/string/wcstok.c (wcstok): ditto.
*libc/string/wcsxfrm.c (wcsxfrm): ditto.
*libc/string/wmemcpy.c (wmemcpy): ditto.

10 years ago * common.din: Export posix_spawn[...] functions.
Corinna Vinschen [Tue, 26 Nov 2013 17:11:09 +0000 (17:11 +0000)]
* common.din: Export posix_spawn[...] functions.
* exec.cc (execve): Add EXPORT_ALIAS _execve.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* posix.sgml (std-susv4):  Add posix_spawn[...] here.
(std-notimpl): Drop here.

10 years ago * nlsfuncs.cc (strcoll): Add "__restrict" to definition.
Corinna Vinschen [Tue, 26 Nov 2013 17:08:56 +0000 (17:08 +0000)]
* nlsfuncs.cc (strcoll): Add "__restrict" to definition.
(strxfrm): Ditto.

10 years ago2013-11-25 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Tue, 26 Nov 2013 14:38:58 +0000 (14:38 +0000)]
2013-11-25  Joel Sherrill <joel.sherrill@oarcorp.com>

        * libc/iconv/lib/iconv.c, libc/time/strftime.c: Change "restrict<" to
        "restrict <" to fix formatting.

10 years ago * libc/posix/posix_spawn.c: Drop using namespace.h.
Corinna Vinschen [Tue, 26 Nov 2013 13:51:19 +0000 (13:51 +0000)]
* libc/posix/posix_spawn.c: Drop using namespace.h.

10 years ago * libc/posix/posix_spawn.c: Eliminate OS function calls not present
Corinna Vinschen [Tue, 26 Nov 2013 13:48:00 +0000 (13:48 +0000)]
* libc/posix/posix_spawn.c: Eliminate OS function calls not present
in newlib or Cygwin.
(process_spawnattr): Use sigprocmask rather than _sigprocmask.  Use
sigaction rather than _sigaction.
(process_file_actions_entry): Use dup2 rather than _dup2.
(do_posix_spawn): Use execvpe rather than _execvpe.  Use waitpid
rather than _waitpid.

10 years ago2013-11-25 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Mon, 25 Nov 2013 17:55:33 +0000 (17:55 +0000)]
2013-11-25  Joel Sherrill <joel.sherrill@oarcorp.com>

* libc/iconv/lib/iconv.c, libc/time/strftime.c: Change "restrict<" to
"restrict <" to fix formatting.

10 years ago * libc/include/spawn.h (posix_spawn_file_actions_destroy): Fix typo
Corinna Vinschen [Mon, 25 Nov 2013 17:23:30 +0000 (17:23 +0000)]
* libc/include/spawn.h (posix_spawn_file_actions_destroy): Fix typo
in function name.
* libc/posix/posix_spawn.c (posix_spawn_file_actions_destroy): Ditto.

10 years ago2013-11-25 Sahil Patnayakuni <sahil.patnayakuni@gmail.com>
Joel Sherrill [Mon, 25 Nov 2013 13:46:23 +0000 (13:46 +0000)]
2013-11-25  Sahil Patnayakuni <sahil.patnayakuni@gmail.com>

* libc/include/time.h (time): Add restrict keyword.
* libc/include/wchar.h (wcsftime): Add restrict keyword.
* libc/time/asctime_r.c (asctime_r): Same.
* libc/time/gmtime_r.c (gmtime_r): Same.
* libc/time/lcltime_r.c (lcltime_r): Same.
* libc/time/strftime.c (strftime): Same.
* libc/time/strptime.c (strptime): Same.
* libc/sys/linux/linuxthreads/timer_create.c (timer_create): Same.
* libc/sys/linux/linuxthreads/timer_settime.c (timer_settime): Same.

10 years ago Throughout, keep function definitions and declarations in sync with
Corinna Vinschen [Mon, 25 Nov 2013 11:38:08 +0000 (11:38 +0000)]
Throughout, keep function definitions and declarations in sync with
newlib in terms of C99 "restrict" keyword.

10 years ago * dtable.cc: Include sys/param.h for MAX definition.
Corinna Vinschen [Sun, 24 Nov 2013 13:01:25 +0000 (13:01 +0000)]
* dtable.cc: Include sys/param.h for MAX definition.

10 years ago Throughout, drop unnecessary explicit includes of windows header files
Corinna Vinschen [Sun, 24 Nov 2013 12:13:36 +0000 (12:13 +0000)]
Throughout, drop unnecessary explicit includes of windows header files
included by default.
* winlean.h: Add long comment to explain why we have to define certain
symbols.
(_NORMALIZE_): Define.
(_WINNLS_): Drop definition and subsequent undef.
(_WINNETWK_): Ditto.
(_WINSVC_): Ditto.

2013-11-23  Eric Blake  <eblake@redhat.com>

10 years ago*** empty log message ***
Corinna Vinschen [Sun, 24 Nov 2013 12:09:18 +0000 (12:09 +0000)]
*** empty log message ***

10 years ago2013-11-23 Bryan Dunsmore <dunsmoreb@gmail.com>
Joel Sherrill [Sat, 23 Nov 2013 22:39:34 +0000 (22:39 +0000)]
2013-11-23 Bryan Dunsmore <dunsmoreb@gmail.com>

* libc/include/wordexp.h (wordexp): Add restrict keyword.
* libc/posix/wordexp.c (wordexp): Ditto.

10 years agodup2: fix off-by-one crash
Eric Blake [Sat, 23 Nov 2013 13:51:53 +0000 (13:51 +0000)]
dup2: fix off-by-one crash

* dtable.cc (dup3): Fix off-by-one.
(find_unused_handle): Reduce time spent expanding during dup.
* syscalls.cc (setdtablesize): Report error on invalid value.

10 years ago * new-features.xml (ov-new1.7.26): Add new section.
Corinna Vinschen [Sat, 23 Nov 2013 11:39:51 +0000 (11:39 +0000)]
* new-features.xml (ov-new1.7.26): Add new section.

10 years ago2013-11-22 Bryan Dunsmore <dunsmoreb@gmail.com>
Joel Sherrill [Sat, 23 Nov 2013 01:25:47 +0000 (01:25 +0000)]
2013-11-22  Bryan Dunsmore <dunsmoreb@gmail.com>

* libc/include/sys/time.h (gettimeofday): Add restrict keyword.
(setitimer): Likewise.
* libc/sys/rdos/gettod.c (gettimeofday): Likewise.
* libc/sys/rtems/crt0.c (gettimeofday): Likewise.

10 years ago2013-11-22 Chirayu Desai <chirayudesai1@gmail.com>
Joel Sherrill [Fri, 22 Nov 2013 22:39:51 +0000 (22:39 +0000)]
2013-11-22  Chirayu Desai  <chirayudesai1@gmail.com>

* libc/include/sys/unistd.h (readlink): Add restrict keyword.
(readlinkat): Ditto.
(swab): Ditto.
* libc/sys/rdos/readlink.c (readlink): Ditto.
* libc/string/swab.c (swab): Ditto.

10 years ago2013-11-21 Daniel Ramirez <javamonn@gmail.com>
Joel Sherrill [Fri, 22 Nov 2013 01:17:42 +0000 (01:17 +0000)]
2013-11-21  Daniel Ramirez <javamonn@gmail.com>

* libc/sys/linux/statvfs.c (statvfs): Added restrict keyword.

10 years ago2013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Thu, 21 Nov 2013 19:27:17 +0000 (19:27 +0000)]
2013-11-21  Joel Sherrill <joel.sherrill@oarcorp.com>

* libc/sys/rdos/chown.c, libc/sys/rdos/close.c, libc/sys/rdos/execve.c,
libc/sys/rdos/fork.c, libc/sys/rdos/fstat.c, libc/sys/rdos/getpid.c,
libc/sys/rdos/gettod.c, libc/sys/rdos/isatty.c, libc/sys/rdos/kill.c,
libc/sys/rdos/link.c, libc/sys/rdos/lseek.c, libc/sys/rdos/open.c,
libc/sys/rdos/rdos.h, libc/sys/rdos/read.c, libc/sys/rdos/readlink.c,
libc/sys/rdos/sbrk.c, libc/sys/rdos/stat.c, libc/sys/rdos/symlink.c,
libc/sys/rdos/times.c, libc/sys/rdos/unlink.c, libc/sys/rdos/wait.c,
libc/sys/rdos/write.c: Convert from DOS to UNIX CRLF.

10 years ago2013-11-21 Julio Gutierrez <jgutleyva@gmail.com>
Joel Sherrill [Thu, 21 Nov 2013 17:04:57 +0000 (17:04 +0000)]
2013-11-21  Julio Gutierrez <jgutleyva@gmail.com>

* libc/include/glob.h (glob): Add restrict keyword.
* libc/posix/glob.c (glob): Ditto.

10 years ago2013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Thu, 21 Nov 2013 16:44:39 +0000 (16:44 +0000)]
2013-11-21  Joel Sherrill <joel.sherrill@oarcorp.com>

* libc/posix/readdir_r.c: Add restrict keyword.
* libc/machine/spu/sys/dirent.h, libc/sys/decstation/sys/dirent.h,
libc/sys/linux/sys/dirent.h, libc/sys/rtems/sys/dirent.h,
libc/sys/sparc64/sys/dirent.h, libc/sys/sun4/sys/dirent.h,
libc/sys/sysvi386/sys/dirent.h: Add readdir_r() prototype.

10 years ago2013-11-21 Daniel Ramirez <javamonn@gmail.com>
Joel Sherrill [Thu, 21 Nov 2013 16:42:17 +0000 (16:42 +0000)]
2013-11-21  Daniel Ramirez <javamonn@gmail.com>

* d30v/syscalls.c, i960/mon960.c, m68k/io-stat.c, mt/stat.c,
spu/lstat.c, spu/stat.c: Add restrict keyword.

10 years ago2013-11-21 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Thu, 21 Nov 2013 16:39:06 +0000 (16:39 +0000)]
2013-11-21  Joel Sherrill <joel.sherrill@oarcorp.com>

* libc/sys/rdos/stat.c: Remove stray +.

10 years ago2013-11-21 Daniel Ramirez <javamonn@gmail.com>
Joel Sherrill [Thu, 21 Nov 2013 16:35:47 +0000 (16:35 +0000)]
2013-11-21  Daniel Ramirez <javamonn@gmail.com>

* libc/include/sys/stat.h, libc/sys/linux/sys/stat.h,
libc/sys/m88kbug/syscalls.c, libc/sys/rdos/stat.c,
libc/sys/sparc64/sys/stat.h: Add restrict keyword.

10 years ago[AArch64] Set errno in ftruncate() and truncate().
Marcus Shawcroft [Thu, 21 Nov 2013 15:53:52 +0000 (15:53 +0000)]
[AArch64] Set errno in ftruncate() and truncate().

10 years ago[ARM] set errno in ftruncate and truncate stubs.
Marcus Shawcroft [Thu, 21 Nov 2013 15:49:05 +0000 (15:49 +0000)]
[ARM] set errno in ftruncate and truncate stubs.

10 years ago2013-11-20 Daniel Ramirez <javamonn@gmail.com>
Joel Sherrill [Wed, 20 Nov 2013 18:22:27 +0000 (18:22 +0000)]
2013-11-20  Daniel Ramirez <javamonn@gmail.com>

* libc/include/search.h, libc/search/tdelete.c: Add restrict keyword.

10 years ago2013-11-20 Chirayu Desai <chirayudesai1@gmail.com>
Joel Sherrill [Wed, 20 Nov 2013 16:25:50 +0000 (16:25 +0000)]
2013-11-20  Chirayu Desai  <chirayudesai1@gmail.com>

* libc/include/regex.h, libc/posix/regcomp.c,
libc/posix/regerror.c, libc/posix/regex.3
libc/posix/regexec.c: Add restrict keyword.

10 years ago2013-11-20 Daniel Ramirez <javamonn@gmail.com>
Joel Sherrill [Wed, 20 Nov 2013 13:39:36 +0000 (13:39 +0000)]
2013-11-20  Daniel Ramirez <javamonn@gmail.com>

* libc/iconv/lib/iconv.c, libc/include/iconv.h,
libc/sys/linux/iconv/iconv.c: Add restrict keyword.

10 years ago * include/cygwin/stdlib.h (realpath): Drop declaration. It's declared
Corinna Vinschen [Wed, 20 Nov 2013 09:48:04 +0000 (09:48 +0000)]
* include/cygwin/stdlib.h (realpath): Drop declaration.  It's declared
in newlib's stdlib.h now.

10 years ago * libc/include/stdlib.h: Declare realpath only if !__STRICT_ANSI__.
Corinna Vinschen [Wed, 20 Nov 2013 09:46:39 +0000 (09:46 +0000)]
* libc/include/stdlib.h: Declare realpath only if !__STRICT_ANSI__.

10 years ago * cygcheck.cc (RtlGetVersion): Declare.
Corinna Vinschen [Tue, 19 Nov 2013 22:26:37 +0000 (22:26 +0000)]
* cygcheck.cc (RtlGetVersion): Declare.
(dump_sysinfo): Call RtlGetVersion rather than GetVersionEx to get
correct OS info even on Windows 8.1.  Don't check return value since
RtlGetVersion never fails per MSDN.  Move fetching kernel32 module
handle where it's really needed.  Drop temporary comment added by
previous checkin.

10 years ago * ntdll.h (RtlGetVersion): Declare.
Corinna Vinschen [Tue, 19 Nov 2013 22:21:11 +0000 (22:21 +0000)]
* ntdll.h (RtlGetVersion): Declare.
* wincap.cc (wincapc::init): Rather than GetVersionEx, call
RtlGetVersion which is not crippled by missing Windows 8.1 manifest.
* wincap.h (wincapc): Change type of version to RTL_OSVERSIONINFOEXW.
Align formatting of all class members.

10 years ago * cygcheck.cc (dump_sysinfo): Revert Windows 8.1 hack. It's not
Corinna Vinschen [Tue, 19 Nov 2013 20:43:04 +0000 (20:43 +0000)]
* cygcheck.cc (dump_sysinfo): Revert Windows 8.1 hack.  It's not
working.  Add a (hopefully temporary) comment.

10 years ago * wincap.cc (wincapc::init): Revert previous change. It's not working.
Corinna Vinschen [Tue, 19 Nov 2013 20:37:27 +0000 (20:37 +0000)]
* wincap.cc (wincapc::init): Revert previous change.  It's not working.

10 years ago3013-11-19 Jennifer Averett <jennifer.averett@oarcorp.com>
Joel Sherrill [Tue, 19 Nov 2013 19:11:24 +0000 (19:11 +0000)]
3013-11-19  Jennifer Averett <jennifer.averett@oarcorp.com>

        * libc/sys/rtems/sys/cpuset.h: New file.

10 years ago*** empty log message ***
Corinna Vinschen [Tue, 19 Nov 2013 18:10:47 +0000 (18:10 +0000)]
*** empty log message ***

10 years ago * net.cc (cygwin_getaddrinfo): Fix a comment. Only memset whints if
Corinna Vinschen [Tue, 19 Nov 2013 18:07:46 +0000 (18:07 +0000)]
* net.cc (cygwin_getaddrinfo): Fix a comment.  Only memset whints if
hints is NULL.  Add a comment and set whints.ai_family explicitely to
AF_UNSPEC to follow glibc man page closely.  Check flags against whints
for locality.

10 years ago * wincap.cc (wincapc::init): Fix dwMinorVersion for Windows 8.1 and
Corinna Vinschen [Tue, 19 Nov 2013 18:01:04 +0000 (18:01 +0000)]
* wincap.cc (wincapc::init): Fix dwMinorVersion for Windows 8.1 and
Server 2012.  Explain why this is necessary.

10 years agoAdd missing entry
Corinna Vinschen [Tue, 19 Nov 2013 17:49:35 +0000 (17:49 +0000)]
Add missing entry

10 years ago * cygcheck.cc (dump_sysinfo): Drop code trying to fetch OSVERSIONINFO
Corinna Vinschen [Tue, 19 Nov 2013 17:44:33 +0000 (17:44 +0000)]
* cygcheck.cc (dump_sysinfo): Drop code trying to fetch OSVERSIONINFO
if fetching OSVERSIONINFOEX failed.  Drop code handling unsupported
platform IDs.  Add code to tweak dwMinorVersion on Windows 8.1 if no
manifest is present.

10 years agoFix date
Joel Sherrill [Tue, 19 Nov 2013 17:39:43 +0000 (17:39 +0000)]
Fix date

10 years ago2013-11-18 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Tue, 19 Nov 2013 17:32:24 +0000 (17:32 +0000)]
2013-11-18  Joel Sherrill <joel.sherrill@oarcorp.com>

* libc/include/stdlib.h: Add prototype of realpath().
* libc/sys/linux/realpath.c: Add restrict keyword.

10 years ago2013-11-19 Joel Sherrill <joel.sherrill@oarcorp.com>
Joel Sherrill [Tue, 19 Nov 2013 17:28:04 +0000 (17:28 +0000)]
2013-11-19  Joel Sherrill <joel.sherrill@oarcorp.com>

* libm/common/modfl.c: Add cast to remove compiler warning.

10 years ago * autoload.cc (IdnToAscii): Define.
Corinna Vinschen [Tue, 19 Nov 2013 13:29:37 +0000 (13:29 +0000)]
* autoload.cc (IdnToAscii): Define.
(IdnToUnicode): Define.
(FreeAddrInfoW): Define.
(GetAddrInfoW): Define.
(GetNameInfoW): Define.
* net.cc: Drop W. Richard STEVENS libgai implementation.
(cygwin_freeaddrinfo): Move code from ipv4_freeaddrinfo here.  Move
definition up in file to avoid forward declaration in ga_duplist.
(ga_dup): Take addrinfoW as input.  Add parameters to get IDN flags
and to set error value.  Handle IDN flags and especially AI_CANONIDN.
Convert input wchar_t ai_canonname string to multibyte for output.
(ga_duplist): Add parameters to get IDN flags and to set error value
and propagate to ga_dup.  Call cygwin_freeaddrinfo.
(gai_errmap): Add comments.  Align error strings to GLibc.  Add
EAI_IDN_ENCODE entry.
(get_ipv6_funcs): Remove.
(load_ipv6_guard): Remove.
(ipv6_inited): Remove.
(load_ipv6): Remove.
(load_ipv6_funcs): Remove.
(cygwin_getaddrinfo): Drop calling load_ipv6.  Handle AI_IDN* flags.
Convert input strings to wchar_t and call GetAddrInfoW/FreeAddrInfoW.
In case hints is NULL, set default ai_flags explicitely to
AI_V4MAPPED | AI_ADDRCONFIG, as documented for Glibc.  Only add AI_ALL
if AI_ADDRCONFIG is not given.  Unconditionally add Windows-specific
AI_DISABLE_IDN_ENCODING to ai_flags to make IDN behaviour compatible
to Glibc even on Windows 8 and later.
(cygwin_getnameinfo): Drop calling load_ipv6.  Handle NI_IDN* flags.
Call GetNameInfoW and convert returned strings from wchar_t to
multibyte.
* include/netdb.h: Add comments to describe flags and error values.
(AI_*): Define all flags using hex values for clearness.
(AI_IDN): Define.
(AI_CANONIDN): Define.
(AI_IDN_ALLOW_UNASSIGNED): Define.
(AI_IDN_USE_STD3_ASCII_RULES): Define.
(NI_*): Define all flags using hex values for clearness.
(NI_IDN): Define.
(NI_IDN_ALLOW_UNASSIGNED): Define.
(NI_IDN_USE_STD3_ASCII_RULES): Define.
(EAI_IDN_ENCODE): Define.

10 years ago * libc/posix/closedir.c: Fix use after free.
Corinna Vinschen [Tue, 19 Nov 2013 11:48:02 +0000 (11:48 +0000)]
* libc/posix/closedir.c: Fix use after free.
Remove useless test dd_fd != -1
* libc/posix/readdir.c: Remove useless test dd_fd == -1
* libc/posix/readdir_r.c: Ditto.

10 years ago * Makefile.in (cygcheck.exe): Link against wininet.dll.
Corinna Vinschen [Tue, 19 Nov 2013 11:14:36 +0000 (11:14 +0000)]
* Makefile.in (cygcheck.exe): Link against wininet.dll.
(dumper.exe): Link against psapi.dll.
* cygcheck.cc (_WIN32_WINNT): Define as 0x0602.
(pInternetCloseHandle): Drop pointer.
(PRODUCT_UNLICENSED): Drop definition.
(PRODUCT_PROFESSIONAL_WMC): Ditto.
(package_grep): Delete code loading wininet functions dynamically, just
call functions directly.

10 years ago*** empty log message ***
Corinna Vinschen [Tue, 19 Nov 2013 10:47:09 +0000 (10:47 +0000)]
*** empty log message ***

10 years ago * cygcheck.cc (dump_sysinfo): Distinguish Windows 8 and 8.1, as well
Corinna Vinschen [Tue, 19 Nov 2013 10:43:10 +0000 (10:43 +0000)]
* cygcheck.cc (dump_sysinfo): Distinguish Windows 8 and 8.1, as well
as Windows Server 2012 and 2012 R2.  Add missing commas in products
array to avoid crashes.  Drop Windows NT4 and 2000 printouts.  Just
call IsWow64Process, GetNativeSystemInfo, and GetDiskFreeSpaceEx
directly, rather than loading them dynamically, since they are exported
by all supported OS versions.  Fix questionable type usage in call to
GetDiskFreeSpaceEx.

10 years ago2013-11-18 Sahil Patnayakuni <sahilp@oarcorp.com>
Joel Sherrill [Mon, 18 Nov 2013 17:28:06 +0000 (17:28 +0000)]
2013-11-18  Sahil Patnayakuni  <sahilp@oarcorp.com>

* libc/include/stdio.h, libc/machine/powerpc/vfscanf.c,
libc/machine/spu/fgetpos.c, libc/machine/spu/fgets.c,
libc/machine/spu/fopen.c, libc/machine/spu/fputs.c,
libc/machine/spu/fread.c, libc/machine/spu/freopen.c,
libc/machine/spu/fwrite.c, libc/machine/spu/setbuf.c,
libc/machine/spu/vfprintf.c, libc/machine/spu/vfscanf.c,
libc/machine/spu/vsnprintf.c, libc/machine/spu/vsprintf.c,
libc/machine/spu/vsscanf.c, libc/stdio/asnprintf.c,
libc/stdio/asprintf.c, libc/stdio/dprintf.c,
libc/stdio/fgetpos.c, libc/stdio/fgets.c,
libc/stdio/fmemopen.c, libc/stdio/fopen.c,
libc/stdio/fprintf.c, libc/stdio/fputs.c,
libc/stdio/fread.c, libc/stdio/freopen.c,
libc/stdio/fscanf.c, libc/stdio/fwrite.c,
libc/stdio/printf.c, libc/stdio/scanf.c,
libc/stdio/setbuf.c, libc/stdio/snprintf.c,
libc/stdio/sprintf.c, libc/stdio/sscanf.c,
libc/stdio/vdprintf.c, libc/stdio/vprintf.c,
libc/stdio/vscanf.c, libc/stdio/vsnprintf.c,
libc/stdio/vsprintf.c, libc/stdio/vsscanf.c: Add restrict keyword.

10 years ago2013-11-18 Sahil Patnayakuni <sahilp@oarcorp.com>
Joel Sherrill [Mon, 18 Nov 2013 17:26:52 +0000 (17:26 +0000)]
2013-11-18  Sahil Patnayakuni  <sahilp@oarcorp.com>

* libc/include/stdlib.h, libc/stdlib/mbstowcs.c,
libc/stdlib/mbstowcs_r.c, libc/stdlib/mbtowc.c,
libc/stdlib/mbtowc_r.c, libc/stdlib/strtod.c,
libc/stdlib/strtol.c, libc/stdlib/strtold.c,
libc/stdlib/strtoll.c, libc/stdlib/strtoll_r.c,
libc/stdlib/strtoul.c, libc/stdlib/strtoull.c,
libc/stdlib/strtoull_r.c, libc/stdlib/wcstombs.c,
libc/stdlib/wcstombs_r.c: Add restrict keyword.

10 years ago[AArch64] Provide ftruncate() and truncate() stubs.
Marcus Shawcroft [Mon, 18 Nov 2013 10:04:56 +0000 (10:04 +0000)]
[AArch64] Provide ftruncate() and truncate() stubs.

10 years ago[ARM] Provide ftruncate() and truncate() stubs.
Marcus Shawcroft [Mon, 18 Nov 2013 09:53:46 +0000 (09:53 +0000)]
[ARM] Provide ftruncate() and truncate() stubs.

10 years ago * newlib/libc/stdlib/getopt.c (getopt_internal): Add missing braces.
Corinna Vinschen [Wed, 13 Nov 2013 20:04:18 +0000 (20:04 +0000)]
* newlib/libc/stdlib/getopt.c (getopt_internal): Add missing braces.

10 years ago * newlib/libc/include/getopt.h (struct option): name field should be
Corinna Vinschen [Wed, 13 Nov 2013 09:09:45 +0000 (09:09 +0000)]
* newlib/libc/include/getopt.h (struct option): name field should be
"const char *".
* newlib/libc/stdlib/getopt.c (getopt_internal): Use fputs()/fputc()
instead of fprintf() to save code space.  Fix signed/unsigned
comparison.

10 years ago * faq-setup.xml (faq.setup.uninstall-service): Describe how to unhook
Corinna Vinschen [Tue, 12 Nov 2013 22:21:32 +0000 (22:21 +0000)]
* faq-setup.xml (faq.setup.uninstall-service): Describe how to unhook
cyglsa DLL from OS before uninstalling.

10 years ago * libc/libc/stdlib/getopt.c (getopt_internal): Fix NULL pointer access.
Corinna Vinschen [Tue, 12 Nov 2013 11:30:32 +0000 (11:30 +0000)]
* libc/libc/stdlib/getopt.c (getopt_internal): Fix NULL pointer access.

10 years ago * faq-setup.xml: Throughout remove setup.exe, use setup or setup-x86...
Corinna Vinschen [Mon, 11 Nov 2013 12:48:31 +0000 (12:48 +0000)]
* faq-setup.xml: Throughout remove setup.exe, use setup or setup-x86...
instead.
(faq.setup.cli): Reproduce latest --help output.
(faq.setup.noroot): New section.
(faq.setup.setup-fails-on-ts): Remove section.
* setup-net.xml (internet-setup): Mention setup-x86{_64} in first
paragraph.  Add note to allow using setup.exe in subsequent paragraphs.
Add paragraph to introduce --no-admin option.

10 years ago * libm/libm.texinfo: Rename node Index to Document Index.
Corinna Vinschen [Fri, 8 Nov 2013 12:48:29 +0000 (12:48 +0000)]
* libm/libm.texinfo: Rename node Index to Document Index.
* libc/libc.texinfo: Rename node Library Index to Document Index.

10 years ago* Makefile.in: Properly cd to directory sans install_ prefix. Report on errors
Christopher Faylor [Thu, 7 Nov 2013 00:29:46 +0000 (00:29 +0000)]
* Makefile.in: Properly cd to directory sans install_ prefix.  Report on errors
on doc install.  Only 'all' is special.

10 years agowinsup/ChangeLog:
Christopher Faylor [Thu, 7 Nov 2013 00:19:52 +0000 (00:19 +0000)]
winsup/ChangeLog:
2013-11-06  Christopher Faylor  <me.cygwin2013@cgf.cx>

* configure.ac: Detect windows headers/libs after we've figured out the
C compiler.
* configure: Regenerate.
* aclocal.m4: Regenerate.
* configure.cygwin: Default to '.' if can't find a winsup directory.

winsup/cygserver/ChangeLog:
2013-11-06  Christopher Faylor  <me.cygwin2013@cgf.cx>

* configure.ac: Detect windows headers/libs after we've figured out the
C compiler.
* configure: Regenerate.
* aclocal.m4: Regenerate.

winsup/cygwin/ChangeLog:
2013-11-06  Christopher Faylor  <me.cygwin2013@cgf.cx>

* configure.ac: Detect windows headers/libs after we've figured out the
C compiler.
* configure: Regenerate.
* aclocal.m4: Regenerate.

winsup/utils/ChangeLog:
2013-11-06  Christopher Faylor  <me.cygwin2013@cgf.cx>

* configure.ac: Detect windows headers/libs after we've figured out the
C compiler.
* configure: Regenerate.
* aclocal.m4: Regenerate.

10 years ago* Makefile.in: Reinstate ignoring of errors for doc target.
Christopher Faylor [Wed, 6 Nov 2013 23:26:23 +0000 (23:26 +0000)]
* Makefile.in: Reinstate ignoring of errors for doc target.

10 years ago * libc/stdio/fvwrite.c: Allow writing in larger chunks for fully
Corinna Vinschen [Mon, 4 Nov 2013 14:18:44 +0000 (14:18 +0000)]
* libc/stdio/fvwrite.c: Allow writing in larger chunks for fully
buffered and unbuffered files, to improve write performance.

10 years ago * devices.in (dev_cygdrive_storage): Revert mapping to \Device\Null.
Corinna Vinschen [Thu, 31 Oct 2013 14:26:42 +0000 (14:26 +0000)]
* devices.in (dev_cygdrive_storage): Revert mapping to \Device\Null.
(dev_storage): Ditto for /dev.
* devices.cc: Regenerate.
* fhandler.cc (fhandler_base::open_null): New method to open a fake
\Device\Null handler.
(fhandler_base::open): Fix formatting.  Change O_ACCMODE test to a
switch statement.  Simplify a test which still tested for a now unused
create_disposition.
* fhandler.h (fhandler_base::open_null): Declare.
(fhandler_netdrive::close): Declare.
* fhandler_dev.cc (fhandler_dev::open): Open fake \Device\Null handle
by just calling new open_null method.
* fhandler_disk_file.cc (fhandler_cygdrive::open): Ditto.
* fhandler_netdrive.cc (fhandler_netdrive::open): Call open_null
rather than setting nohandle.
(fhandler_netdrive::close): New method.
* fhandler_registry.cc (fetch_hkey): Fix token in RegOpenUserClassesRoot
call.  Create valid key for HKEY_CURRENT_CONFIG by mapping to real key
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Hardware Profiles\Current.
(fhandler_registry::open): Set nohandle only when using pseudo registry
handle.
* fhandler_virtual.cc (fhandler_virtual::opendir): Call open rather
than just setting nohandle here.
* fhandler_virtual::fstatvfs): Set ST_RDONLY fs flag.
* globals.cc (ro_u_null): New readonly UNICODE_STRING for \Device\Null.
* path.h (path_conv::set_path): Revert previous change caring for
wide_path.

10 years ago * libc/stdio/fvwrite.h: change type of uio_resid from int to size_t to
Corinna Vinschen [Thu, 31 Oct 2013 10:35:54 +0000 (10:35 +0000)]
* libc/stdio/fvwrite.h: change type of uio_resid from int to size_t to
fix fwrite() of > 2GByte buffers.

10 years ago Implement malloc_stats for nano.
Corinna Vinschen [Wed, 30 Oct 2013 15:53:05 +0000 (15:53 +0000)]
Implement malloc_stats for nano.
* libc/stdlib/nano-mallocr.c (RONECALL): New parameter macro.
(sbrk_start): New variable.
(current_mallinfo, free_list): Forward declaration of data.
(chunk): Define size as long type.
(mallinfo): Synchronize with latest malloc.h.
(nano_*): Forward declaration of functions.
(get_chunk_from_ptr): Defined to static inline.
(nano_mallinfo): Implement this function.
(nano_malloc_stats): Implement this function.

10 years ago * libc/include/machine/_default_types.h: Revert change from 2013-10-10.
Corinna Vinschen [Wed, 30 Oct 2013 15:51:13 +0000 (15:51 +0000)]
* libc/include/machine/_default_types.h: Revert change from 2013-10-10.

10 years ago*** empty log message ***
Corinna Vinschen [Wed, 30 Oct 2013 10:00:32 +0000 (10:00 +0000)]
*** empty log message ***

10 years ago * devices.in (dev_cygdrive_storage): Map to \Device\Null.
Corinna Vinschen [Wed, 30 Oct 2013 09:44:47 +0000 (09:44 +0000)]
* devices.in (dev_cygdrive_storage): Map to \Device\Null.
(dev_storage): Map /dev and /dev/windows to \Device\Null.
* devices.cc: Regenerate.
* dir.cc (opendir): Create unique id.  Explain why.
* fhandler.h (fhandler_dev::get_dev): Implement inline.
(fhandler_cygdrive::close): Drop declaration.
(fhandler_cygdrive::get_dev): Implement inline.
(fhandler_windows::get_hwnd): Ditto.
(fhandler_windows::set_close_on_exec): Drop declaration.
(fhandler_windows::fixup_after_fork): Ditto.
* fhandler_dev.cc (fhandler_dev::open): Call fhandler_disk_file::open
without O_CREAT flag.  Explain why.  Create \Device\Null handle if
/dev/ doesn't actually exist.
(fhandler_dev::close): Drop nohandle case.
(fhandler_dev::fstatvfs): Drop nohandle check.  Test for fs_got_fs
instead.  Set ST_RDONLY fs flag for simulated /dev.
(fhandler_dev::opendir): If /dev doesn't exist, call open() to create
fake \Device\Null handle.  Don't set nohandle.  Set dir_exists
correctly.
(fhandler_dev::rewinddir): Call fhandler_disk_file::rewinddir only if
/dev is a real directory.
* fhandler_disk_file.cc (fhandler_disk_file::opendir): If called for
the cygdrive dir, call open() to create fake \Device\Null handle.
Only attach __DIR_mounts buffer to dir if not called for cygdrive dir.
Don't set nohandle.
(fhandler_cygdrive::open): Create \Device\Null handle.
(fhandler_cygdrive::close): Remove.
(fhandler_cygdrive::fstatvfs): Set ST_RDONLY fs flag.
* fhandler_windows.cc (fhandler_windows::open): Create \Device\Null
handle.
(fhandler_windows::read): Don't add io_handle to WFMO handle array.
Change subsequent test for return value accordingly.  Fix test for
"message arrived".
(fhandler_windows::set_close_on_exec): Remove.
(fhandler_windows::fixup_after_fork): Remove.
* path.h (path_conv::set_path): Make sure wide_path is NULL when
setting a new path.
* select.cc (peek_windows): Use correct hWnd value, not io_handle.
(fhandler_windows::select_read): Don't use io_handle as wait object.
(fhandler_windows::select_write): Ditto.
(fhandler_windows::select_except): Ditto.

10 years agomerge from gcc
DJ Delorie [Tue, 29 Oct 2013 15:14:27 +0000 (15:14 +0000)]
merge from gcc

10 years ago*** empty log message ***
Corinna Vinschen [Mon, 28 Oct 2013 10:57:33 +0000 (10:57 +0000)]
*** empty log message ***

10 years ago * exception.h: Fold in content of include/exceptions.h.
Corinna Vinschen [Sun, 27 Oct 2013 09:42:17 +0000 (09:42 +0000)]
* exception.h: Fold in content of include/exceptions.h.
* include/exceptions.h: Remove.

10 years ago * devices.in (dev_storage): Map /dev/dsp to \Device\Null.
Corinna Vinschen [Sat, 26 Oct 2013 13:23:54 +0000 (13:23 +0000)]
* devices.in (dev_storage): Map /dev/dsp to \Device\Null.
* devices.cc: Regenerate.
* fhandler_dsp.cc (fhandler_dev_dsp::open): Call fhandler_base::open.
(fhandler_dev_dsp::close): Call fhandler_base::close.
(fhandler_dev_dsp::fixup_after_fork): Call
fhandler_base::fixup_after_fork.

* fhandler_raw.cc (fhandler_dev_raw::fixup_after_fork): Call
fhandler_base::fixup_after_fork.

10 years ago * exception.h (_exception_list): Drop redefinition for x86_64.
Corinna Vinschen [Sat, 26 Oct 2013 09:37:34 +0000 (09:37 +0000)]
* exception.h (_exception_list): Drop redefinition for x86_64.
* include/exceptions.h: Disable content for x86_64 since it's not
using frame based exception handling anymore.

10 years ago * flock.cc (fhandler_base::lock): Only refuse to lock nohandle and
Corinna Vinschen [Fri, 25 Oct 2013 18:40:57 +0000 (18:40 +0000)]
* flock.cc (fhandler_base::lock): Only refuse to lock nohandle and
old-style console devices when called to perform BSD flock locking.
Add a FIXME to comment and align description.

* ntdll.h (THREADINFOCLASS): Following MSDN, rename throughout from
THREAD_INFORMATION_CLASS.

10 years ago * devices.in (dev_storage): Map /dev/clipboard to \Device\Null.
Corinna Vinschen [Fri, 25 Oct 2013 16:16:50 +0000 (16:16 +0000)]
* devices.in (dev_storage): Map /dev/clipboard to \Device\Null.
* devices.cc: Regenerate.
* fhandler.h (fhandler_dev_clipboard::open): Drop declaration.
* fhandler_clipboard.cc (fhandler_dev_clipboard::dup): Drop call to
open.  Set private members to 0 and call fhandler_base::dup.
(fhandler_dev_clipboard::open): Remove so that default
fhandler_base::open is used to open \Device\Null.
(set_clipboard): Drop gratuitios call to RegisterClipboardFormatW.
(fhandler_dev_clipboard::close): Call fhandler_base::close from here.

10 years ago * fhandler_disk_file.cc (fhandler_base::fstat_fs): Fix comment.
Corinna Vinschen [Fri, 25 Oct 2013 15:33:51 +0000 (15:33 +0000)]
* fhandler_disk_file.cc (fhandler_base::fstat_fs): Fix comment.

10 years ago * fhandler_clipboard.cc (fhandler_dev_clipboard::open): Drop gratuitios
Corinna Vinschen [Fri, 25 Oct 2013 15:04:24 +0000 (15:04 +0000)]
* fhandler_clipboard.cc (fhandler_dev_clipboard::open): Drop gratuitios
handling of membuffer.  It's NULL anyway.
(fhandler_dev_clipboard::lseek): Set membuffer to NULL after freeing
it to avoid subsequent crashes when accessing invalid pointer.

10 years ago * devices.in (dev_storage): Map /dev/random and /dev/urandom to
Corinna Vinschen [Fri, 25 Oct 2013 12:21:59 +0000 (12:21 +0000)]
* devices.in (dev_storage): Map /dev/random and /dev/urandom to
\Device\Null.
* devices.cc: Regenerate.
* fhandler.h (fhandler_dev_random::open): Drop declaration.
(fhandler_dev_random::close): Ditto.
(fhandler_dev_random::crypt_gen_random): Convert to static method.
* fhandler_random.cc (fhandler_dev_random::open): Remove so that default
fhandler_base::open is used to open \Device\Null.
(fhandler_dev_random::close): Ditto.
* fhandler_socket.cc (entropy_source): Delete.
(fhandler_socket::af_local_set_secret): Remove entropy_source code and
call fhandler_dev_random::crypt_gen_random directly instead.

10 years ago * fhandler.h (fhandler_dev_zero::lseek): Convert to inline method.
Corinna Vinschen [Thu, 24 Oct 2013 17:51:41 +0000 (17:51 +0000)]
* fhandler.h (fhandler_dev_zero::lseek): Convert to inline method.
(class fhandler_dev_random): Drop dummy_offset.
(fhandler_dev_random::lseek): Convert to inline method.
(fhandler_dev_dsp::lseek): Ditto.
* fhandler_dsp.cc (fhandler_dev_dsp::lseek): Drop here.
* fhandler_random.cc (fhandler_dev_random::open): Drop setting
dummy_offset.
(fhandler_dev_random::lseek): Drop here.
* fhandler_tape.cc (fhandler_dev_tape::lseek): Make no-op, but keep
old code for reference.
* fhandler_zero.cc (fhandler_dev_zero::lseek): Drop here.

10 years ago* external.cc (fillout_pinfo): If start_time is 0, wait a while before
Christopher Faylor [Thu, 24 Oct 2013 15:26:21 +0000 (15:26 +0000)]
* external.cc (fillout_pinfo): If start_time is 0, wait a while before
returning the pinfo structure.
* fhandler.cc (fhandler_base::open_setup): Convert from inline.
* fhandler.h (fhandler_base::open_setup): Declare.
* fhandler_console.cc (fhandler_console::open_setup): Always call
fhandler_base::open_setup.
* fhandler_tty.cc (fhandler_pty_slave::open_setup): Ditto.
(fhandler_pty_master::open_setup): Ditto.

10 years agoFix typo.
Corinna Vinschen [Thu, 24 Oct 2013 11:27:21 +0000 (11:27 +0000)]
Fix typo.

10 years ago * devices.in (dev_storage): Map /dev/zero and /dev/full to \Device\Null.
Corinna Vinschen [Thu, 24 Oct 2013 09:41:17 +0000 (09:41 +0000)]
* devices.in (dev_storage): Map /dev/zero and /dev/full to \Device\Null.
* devices.cc: Regenerate.
* dtable.h (struct dtable): Make fhandler_base friend, rather
than fhandler_disk_file.
* fhandler.cc (fhandler_base::open_with_arch): Create unique id.
(fhandler_base::cleanup): Call del_my_locks.
(fhandler_base::fcntl): Handle F_GETLK, F_SETLK and F_SETLKW.
* fhandler.h (fhandler_base::get_dev): Return real device number.
(fhandler_base::set_unique_id): New inline method.
(fhandler_disk_file::lock): Drop declaration.
(fhandler_disk_file::get_dev): New method, return pc.fs_serial_number.
(fhandler_dev_zero::open): Drop declaration.
* fhandler_disk_file.cc (fhandler_disk_file::close): Move
del_my_locks call to fhandler_base::open_with_arch.
(fhandler_disk_file::fcntl): Move handling of locking commands to
fhandler_base::fcntl.
(fhandler_base::open_fs): Drop call to NtAllocateLocallyUniqueId.
* fhandler_zero.cc (fhandler_dev_zero::open): Remove so that default
fhandler_base::open is used to open \Device\Null.
* flock.cc (fixup_lockf_after_exec): Finding a single fhandler is
enough here.
(fhandler_base::lock): Replace fhandler_disk_file::lock.  Refuse to lock
nohandle devices.  Handle read/write test using POSIX flags.  Explain
why.  Never fail on SEEK_CUR or SEEK_END, rather assume position 0,
just as Linux.
* net.cc (fdsock): Create unique id.

10 years ago * libc/include/stdio.h [!__LARGE64_FILES] (funopen): Fix typo
Hans-Peter Nilsson [Thu, 24 Oct 2013 01:21:33 +0000 (01:21 +0000)]
* libc/include/stdio.h [!__LARGE64_FILES] (funopen): Fix typo
in last change.

10 years agomerge from gcc
DJ Delorie [Wed, 23 Oct 2013 22:37:24 +0000 (22:37 +0000)]
merge from gcc

10 years ago * include /cygwin/config.h (_READ_WRITE_BUFSIZE_TYPE): Define.
Corinna Vinschen [Wed, 23 Oct 2013 10:06:17 +0000 (10:06 +0000)]
* include /cygwin/config.h (_READ_WRITE_BUFSIZE_TYPE): Define.

10 years ago * libc/include/stdio.h (funopen): Change prototype of
Corinna Vinschen [Wed, 23 Oct 2013 10:04:43 +0000 (10:04 +0000)]
* libc/include/stdio.h (funopen): Change prototype of
__readfn and __writefn parameter to match new definition of
FILE's _read and _write methods.
(_funopen_r): Ditto.
(funopen): Ditto.
(_funopen_r): Ditto.
* libc/include/sys/config.h (_READ_WRITE_BUFSIZE_TYPE) Define
as type int if not already defined.  Add comment to explain.
* libc/include/sys/reent.h: Include stddef.h.
(struct __sFILE): Change type of last parameter in declaration
of _read and _write methods to _READ_WRITE_BUFSIZE_TYPE.
(struct __sFILE64): Ditto.
* libc/stdio/local.h (__sread): Declare with last parameter set
to _READ_WRITE_BUFSIZE_TYPE.
(__seofread): Ditto.
(__swrite): Ditto.
(__swrite64): Ditto.
* libc/stdio/fvwrite.c (__sfvwrite_r): Change type of local
variables w and s to _READ_WRITE_RETURN_TYPE.
* libc/stdio/fflush.c (__sflush_r): Change type of local variables
n and t to _READ_WRITE_BUFSIZE_TYPE and _READ_WRITE_RETURN_TYPE.
Add local variables flags to keep _flags value.
* libc/stdio/fmemopen.c (fmemreader): Align to above change.
(fmemwriter): Ditto.
* libc/stdio/fopencookie.c (fcreader): Ditto.
(fcwriter): Ditto.
* libc/stdio/funopen.c (funread): Ditto.
(funwrite): Ditto.
(funreader): Ditto.
(funwriter): Ditto.
* libc/stdio/open_memstream.c (memwriter): Ditto.
* libc/stdio/stdio.c (__sread): Ditto.
(__seofread): Ditto.
(__swrite): Ditto.
* libc/stdio64/stdio64.c (__swrite64): Ditto.

10 years ago * fhandler.cc (fhandler_base::fstat): Drop FH_FULL case to align
Corinna Vinschen [Wed, 23 Oct 2013 09:58:12 +0000 (09:58 +0000)]
* fhandler.cc (fhandler_base::fstat): Drop FH_FULL case to align
/dev/full permissions to Linux.

10 years ago* fhandler.h (fhandler_base::cleanup): Mark as extern rather than inline.
Christopher Faylor [Tue, 22 Oct 2013 20:41:09 +0000 (20:41 +0000)]
* fhandler.h (fhandler_base::cleanup): Mark as extern rather than inline.
* fhandler_base.cc (fhandler_base::cleanup): Define.
* fhandler_tty.cc (fhandler_pty_slave::cleanup): Call fhandler_base::cleanup.
(fhandler_pty_master::cleanup): Ditto.

10 years ago.
Christopher Faylor [Sat, 19 Oct 2013 14:37:29 +0000 (14:37 +0000)]
.

This page took 0.075307 seconds and 5 git commands to generate.