Eric Blake
96b998db51
strerror_r: fix compilation bug in previous patch
...
* errno.cc (includes): Avoid compilation failure if <string.h>
settles on wrong strerror_r signature.
2011-02-10 20:25:54 +00:00
Eric Blake
f6b802d912
* new-features.sgml (ov-new1.7.8): Document strerror_r fixes.
2011-02-10 17:38:18 +00:00
Eric Blake
3c9abad56b
strerror_r: obey POSIX, and match newlib header change
...
* errno.cc (__xpg_strerror_r): New function.
(strerror_r): Update to copy newlib's fixes.
(strerror): Set errno on failure.
(_sys_errlist): Cause EINVAL failure for reserved values.
* cygwin.din: Export new function.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Combine
this into minor 236.
2011-02-10 17:36:51 +00:00
Eric Blake
7c10a76dec
strerror_r: provide POSIX implementation
...
* libc/include/string.h (strerror_r): Update declaration.
* libc/string/strerror.c (strerror): Update documentation.
* libc/string/strerror_r.c (strerror_r): Always return
NUL-terminated string; don't overwrite too-short buf.
* libc/string/xpg_strerror_r.c (__xpg_strerror_r): Implement POSIX
variant.
* libc/string/Makefile.am (GENERAL_SOURCES): Build new file.
* libc/string/Makefile.in: Regenerate.
2011-02-10 16:48:18 +00:00
Yaakov Selkowitz
27aaf2a9d1
* new-features.sgml (ov-new1.7.8): Document pthread_yield.
2011-02-10 10:58:28 +00:00
Yaakov Selkowitz
3696acf497
* cygwin.din (pthread_yield): Export as alias to sched_yield.
...
* include/pthread.h (pthread_yield): Declare.
* include/cygwin/version.h (CYGWIN_VERSION_API_MINOR): Bump.
* posix.sgml (std-deprec): Add pthread_yield.
2011-02-10 10:51:14 +00:00
Christopher Faylor
ca1953eeee
* cygheap.cc: Add some __stdcall decoration where appropriate.
...
* lib/cygwin_crt0.c: __attribute -> __attribute__.
2011-02-10 02:22:36 +00:00
Christopher Faylor
27239c6372
* hookapi.cc (hook_or_detect_cygwin): Prevent i from being considered
...
uninitialized by gcc.
2011-02-09 15:46:00 +00:00
Christopher Faylor
7a5f322c35
* exception.h: Remove DEBUG_EXCEPTION left over debugging ifdef.
...
* dll_init.cc: Fix typo in comment.
2011-02-09 15:40:37 +00:00
Christopher Faylor
38286e47f0
* dll_init.cc: Fix typo in comment.
2011-02-08 20:14:37 +00:00
Ulrich Weigand
e9857afa1c
include/ChangeLog:
...
* dwarf2.h (enum dwarf_calling_convention): Add DW_CC_GDB_IBM_OpenCL.
gdb/ChangeLog:
* dwarf2read.c (read_subroutine_type): Set special calling
convention flag for functions compiled by IBM XL C for OpenCL.
* ppc-sysv-tdep.c: Include "dwarf2.h"
(ppc_sysv_abi_push_dummy_call): Implement IBM OpenCL vector types
calling convention.
(do_ppc_sysv_return_value): Add FUNC_TYPE argument. Implement
IBM OpenCL vector types calling convention.
(ppc_sysv_abi_return_value): Pass through FUNC_TYPE.
(ppc_sysv_abi_broken_return_value): Likewise.
(ppc64_sysv_abi_push_dummy_call): Implement IBM OpenCL vector
types calling convention.
(ppc64_sysv_abi_return_value): Likewise.
* spu-tdep.c: Include "dwarf2.h"
(spu_return_value): Implement IBM OpenCL vector types calling
convention.
gdb/testsuite/ChangeLog:
* gdb.opencl/callfuncs.cl: New file.
* gdb.opencl/callfuncs.exp: New test.
* gdb.opencl/Makefile.in (EXECUTABLES): Add callfuncs.
2011-02-08 13:30:10 +00:00
Corinna Vinschen
4bd8eb7d1b
* configure.in: Remove AC_ALLOCA test and test for __builtin_memset.
...
* configure: Regenerate.
2011-02-07 16:22:02 +00:00
Corinna Vinschen
c3099d3d42
Fix path in ChangeLog entry
2011-02-07 11:36:04 +00:00
Corinna Vinschen
050d09e873
* fhandler_console.cc (fhandler_console::write_normal): Remove
...
erroneous premature return after collecting truncated multibyte
sequence in trunc_buf. Rather fall through to printing routine.
Fix return value to take trunc_buf content into account. Improve
comments.
2011-02-07 11:18:19 +00:00
Christopher Faylor
63398011f9
* autoload.cc (wsock_init): Properly define WSAStartup function pointer to
...
avoid stack damage.
2011-02-05 19:38:21 +00:00
Bernd Schmidt
103e45ba4d
gas/
...
* doc/as.texinfo (Target TIC6X options): Don't mention "-matomic".
* doc/c-tic6x.texi (TIC6X Directives): Don't mention ".atomic".
(TIC6X Options): Don't mention "-matomic".
* config/tc-tic6x.c (OPTION_MATOMIC, OPTION_MNO_ATOMIC): Delete.
(md_longopts): Remove corresponding entries.
(md_parse_option): Don't handle them.
(md_show_usage): Don't document them.
(tic6x_atomic): Delete variable.
(tic6x_update_features): Always copy tic6x_arch_enable to
tic6x_features.
(tic6x_arch_enable): Remove references to TIC6X_INSN_ATOMIC.
(s_tic6x_atomic, s_tic6x_noatomic): Remove functions.
(md_pseudo_table): Remove ".atomic" and ".noatomic".
gas/testsuite/
* gas/tic6x/dir-junk.l: Remove tests for .atomic and .noatomic.
* gas/tic6x/dir-junk.s: Likewise.
* gas/tic6x/insns-c674x-bad.d: Remove test.
* gas/tic6x/insns-c674x-bad.l: Likewise.
* gas/tic6x/insns-atomic.d: Remove "-matomic" switch.
include/opcode/
* tic6x-opcode-table.h (cmtl, ll, sl): Available on C64XP.
* tic6x.h (TIC6X_INSN_ATOMIC): Remove.
2011-02-03 23:20:26 +00:00
Jeff Johnston
42583e8a0b
Fix spelling of Ralf Corsepius' name in ChangeLog.
2011-02-03 22:25:04 +00:00
Corinna Vinschen
b148ba7af2
* libc/bsdlib.cc: Include err.h.
2011-02-02 15:17:14 +00:00
Corinna Vinschen
b22bd786e3
* include/err.h: Fix loss of semicolons in previous patch.
2011-02-02 15:14:46 +00:00
Corinna Vinschen
0cda941fa1
* include/err.h (err): Add noreturn attribute.
...
(errx): Ditto.
(verr): Ditto.
(verrx): Ditto.
2011-02-02 10:16:30 +00:00
Corinna Vinschen
cecc445d5c
* path.cc (conv_path_list): Remove enclosing quotes and trailing
...
backslashes from Win32 environment path lists.
2011-02-02 09:59:10 +00:00
Corinna Vinschen
0e126cb141
* fhandler.cc (fhandler_base::fsync): Ignore ERROR_INVALID_FUNCTION
...
error from FlushFileBuffers().
2011-02-01 08:46:48 +00:00
Corinna Vinschen
2daa7e07ce
* syscalls.cc (utmp_data): Fix potential buffer overflow.
2011-01-31 13:58:59 +00:00
Corinna Vinschen
adef8606bd
* fhandler_socket.cc (address_in_use): Improve comment readability.
2011-01-31 08:53:57 +00:00
Alexandre Oliva
3bd3027c34
PR libgcj/44341
...
* configure.ac: Discard --with-* flags for host when configuring
target libraries for cross build.
* configure: Rebuilt.
2011-01-31 05:26:01 +00:00
Corinna Vinschen
a01454811a
* fhandler_socket.cc (address_in_use): Disable. Add comment.
...
(fhandler_socket::bind): Change comment to explain setting the
SO_EXCLUSIVEADDRUSE socket option. Remove code which checks for
address in use.
* net.cc (cygwin_setsockopt): Never set SO_REUSEADDR option. Improve
comment to compensate for the deleted comment in fhandler_socket::bind.
* wincap.cc: Throughout, drop has_enhanced_socket_security from wincaps.
* wincap.h (struct wincaps): Drop has_enhanced_socket_security flags
and method.
2011-01-30 21:52:12 +00:00
Christopher Faylor
9ce2a54f70
winsup:
...
* configure.in: Configure winsup/cygserver regardless of cross_host.
* configure: Regenerate.
winsup/cygwin:
* configure.in: Define LIBSERVER regardless of cross_host.
* configure: Regenerate.
2011-01-29 06:41:28 +00:00
Corinna Vinschen
93a4d9d97c
* fhandler_socket.cc (fhandler_socket::wait_for_events): Call
...
pthread_testcancel in case of timeout to enable pthread_cancel
on waiting thread.
2011-01-28 11:17:29 +00:00
Corinna Vinschen
656df313e0
* libc/stdio/fclose.c: Only use sfp lock to guard non-atomic
...
changes of flags and fp lock.
* libc/stdio/freopen.c: Ditto.
* libc/stdio/freopen64.c: Ditto.
* libc/stdio/fgetc.c: Revert change from 2009-04-24, remove sfp locks
which guard entire function to avoid potential deadlocks when using
stdio functions in multiple thraeds.
* libc/stdio/fgets.c: Ditto.
* libc/stdio/fgetwc.c: Ditto.
* libc/stdio/fgetws.c: Ditto.
* libc/stdio/fread.c: Ditto.
* libc/stdio/fseek.c: Ditto.
* libc/stdio/getc.c: Ditto.
* libc/stdio/getdelim.c: Ditto.
* libc/stdio/gets.c: Ditto.
* libc/stdio/vfscanf.c: Ditto.
* libc/stdio/vfwscanf.c: Ditto.
* libc/stdio/fflush.c (_fflush_r): Split out core functionality into
new function __sflush_r. Just lock file and call __sflush_r from here.
* libc/stdio/fwalk.c (_fwalk): Remove static helper function and move
functionality back into main function. Don't walk a file with flags
value of 1. Add comment.
(_fwalk_reent): Ditto.
* libc/stdio/local.h (__sflush_r): Declare.
* libc/stdio/refill.c (__srefill): Before calling fwalk, set flags
value to 1 so this file pointer isn't walked. Revert flags afterwards
and call __sflush_r for this fp if necessary. Add comments.
2011-01-28 10:49:11 +00:00
Corinna Vinschen
b5ca0d7271
* include/features.h (__STDC_ISO_10646__): Move to newlib's
...
sys/features.h.
2011-01-27 11:55:51 +00:00
Corinna Vinschen
7cc6d7cfc6
* libc/include/sys/features.h: Define __STDC_ISO_10646__ for Cygwin.
...
* libc/include/wchar.h: Include features.h.
2011-01-27 11:55:01 +00:00
Corinna Vinschen
40aca06884
* fhandler_disk_file.cc (fhandler_base::fstat_by_nfs_ea): Fix
...
computation of st_blocks.
(fhandler_base::fstat_helper): Fix formatting.
2011-01-26 10:55:13 +00:00
Corinna Vinschen
cd06f7049b
* include/features.h (__STDC_ISO_10646__): Define. Add comment.
2011-01-24 16:27:35 +00:00
Andreas Schwab
5623c49951
Sync toplevel configure from GCC
...
2011-01-21 Andreas Schwab <schwab@redhat.com>
* configure.ac: Use AS_HELP_STRING throughout.
* configure: Regenerate.
2011-01-18 Jie Zhang <jie.zhang@analog.com>
* configure.ac (bfin-*-*): Remove gdb from noconfigdirs.
* configure: Regenerate.
2011-01-21 13:29:47 +00:00
Corinna Vinschen
a1c35b8b65
* syscalls.cc (rename): Fix permission problem with symlinks on NFS.
...
Rework how NtOpenFile gets called to make it more readable. Change
comment.
2011-01-21 13:13:00 +00:00
Corinna Vinschen
2aba945c95
* exec.cc: Include pinfo.h.
...
* winf.h: Move definitions of _P_PATH_TYPE_EXEC and _P_MODE from here...
* pinfo.h: ...to here.
(_P_PATH_TYPE_EXEC): Redefine to be bigger than _P_SYSTEM.
(_P_MODE): Redefine so as not to mask out _P_SYSTEM.
* spawn.cc (spawnlp): Add _P_PATH_TYPE_EXEC flag in call to spawnve.
(spawnlpe): Ditto.
(spawnvp): Ditto.
2011-01-20 11:09:21 +00:00
Corinna Vinschen
9b68968b21
* spawn.cc (av::fixup): Reenable #! handling for all exec functions.
...
Return ENOEXEC in !p_type_exec case only for unrecognized files.
Fix comment formatting.
2011-01-19 14:59:10 +00:00
Corinna Vinschen
1393f63206
* exec.cc (execlp): Add missing _P_PATH_TYPE_EXEC flag in call to
...
spawnve.
2011-01-19 10:30:39 +00:00
Corinna Vinschen
26b070c0cf
* exec.cc: Rearrange functions in alphabetical order.
...
(_execve): Drop temporary define and drop export alias.
(execl): Call spawnve.
(execle): New function.
(execlp): New function.
(execv): Call spawnve.
(execve): Drop converting NULL envp to emtpy envp.
(execvp): Call spawnve.
(execvpe): Drop converting NULL envp to emtpy envp. Call spawnve.
(fexecve): Call spawnve.
* spawn.cc (spawnve): Convert NULL envp to emtpy envp. Remove outdated
comment.
(spawnlp): Call spawnve.
(spawnlpe): Ditto.
(spawnvp): Ditto.
(spawnvpe): Fix formatting.
2011-01-19 10:28:39 +00:00
Corinna Vinschen
17133a85de
* exec.cc (strccpy): Move function from here...
...
* strfuncs.cc (strccpy): ...to here.
* string.h (strccpy): Declare.
* winsup.h (strccpy): Drop declaration.
2011-01-19 09:41:54 +00:00
Corinna Vinschen
808aae3d13
* errno.cc (errmap): Add error codes for invalid binaries.
...
* exec.cc (execvp): Call spawnve with _P_PATH_TYPE_EXEC flag
from here.
(execvpe): Ditto.
* spawn.cc (spawn_guts): Filter _P_PATH_TYPE_EXEC from mode and
store in p_type_exec. Call av::fixup with addtional p_type_exec
argument.
(spawnve): Check for filtered mode.
(spawnvpe): Add _P_PATH_TYPE_EXEC flag when calling spawnve.
(av::fixup): Accept additional bool parameter p_type_exec. Only check
for script if p_type_exec is true.
* winf.h (_P_PATH_TYPE_EXEC): Define.
(_P_MODE): Define.
(av::fixup): Declare with additional bool parameter.
2011-01-19 09:15:17 +00:00
Corinna Vinschen
fc660168bf
* fhandler_proc.cc (format_proc_partitions): Fix compiler warning.
2011-01-17 14:31:30 +00:00
Corinna Vinschen
be37165114
* path.cc (path_conv::check): Don't follow reparse point symlinks if
...
PC_SYM_NOFOLLOW_REP flag is set.
(cygwin_conv_path): Set PC_SYM_NOFOLLOW_REP flag when converting from
POSIX to Win32.
* path.h (enum pathconv_arg): Define PC_SYM_NOFOLLOW_REP flag.
2011-01-17 14:19:39 +00:00
Corinna Vinschen
483e9d0022
* fhandler_proc.cc (proc_tab_cmp): Fix typo in comment.
...
(fhandler_proc::fill_filebuf): Handle return value of 0 from format
function as error.
(format_proc_stat): Set errno when returning 0 size.
(format_proc_partitions): Rewrite method to fetch partition info.
2011-01-17 13:38:06 +00:00
Corinna Vinschen
d6d9c269e4
* libc/include/sys/types.h (ulong): Add typedef.
2011-01-15 09:26:16 +00:00
Ralf Wildenhues
d5802f24ce
Backport from Libtool: Fix relink mode to use absolute path if hardcode_minus_L.
...
/:
* ltmain.sh (relink): Use absolute path when hardcoding with -L.
2011-01-13 18:52:53 +00:00
Joel Brobecker
e82bcd79cd
port GDB to ia64-hpux (native).
...
ChangeLog:
* configure.ac: Remove readline, mmalloc, and gdb from noconfigdirs
for ia64-hpux.
* configure: Regenerate.
gdb/ChangeLog:
* config/ia64/hpux.mh, ia64-hpux-nat.c, ia64-hpux-tdep.c,
ia64-hpux-tdep.h, solib-ia64-hpux.c, solib-ia64-hpux.h: New files.
* configure.host: Add handling for ia64-hpux hosts. Add associated
floatformats.
* configure.tgt: Add handling for ia64-hpux targets.
* Makefile.in (ALL_64_TARGET_OBS): Add ia64-hpux-tdep.o.
(HFILES_NO_SRCDIR): Add ia64-hpux-tdep.h.
(ALLDEPFILES): Add ia64-hpux-nat.c ia64-hpux-tdep.c.
2011-01-13 16:24:08 +00:00
Corinna Vinschen
49d31b4e82
Fix typo, fix copyright
2011-01-13 14:00:00 +00:00
Corinna Vinschen
07c43238cf
* fhandler_disk_file.cc (fhandler_base::fstat_helper): Alwasy set
...
st_size of directories to 0. Explain why.
2011-01-13 13:50:02 +00:00
Corinna Vinschen
cf8d5ec5ae
Really check in now
2011-01-13 13:48:12 +00:00