Corinna Vinschen [Sat, 31 Mar 2001 09:19:32 +0000 (09:19 +0000)]
* fhandler.h (class fhandler_console): Add members `insert_mode'.
* fhandler_console.cc (fhandler_console::dup): Duplicate `insert_mode'.
(fhandler_console::fhandler_console): Initialize `insert_mode'.
fhandler_console::char_command): Add terminal capabilities
"enter insert mode" = \E[4h and "exit insert mode" = \E[4l.
Care for insert mode on terminal capability "repeat char" = \E[x;yb.
(fhandler_console::write_normal): Care for insert mode before writing
to the console.
(array keytable): Add keymapping for modified cursor and control
block keys (xterm like).
* lib/_cygwin_S_IEXEC.c: Remove "const" from globals or they never seem to be
defined. Wrap definitions in extern "C". Include winsup.h to assure proper
definitions.
* dcrt0.cc (dll_crt0_1): Call stdio_init after premain run so that binmode.o,
etc., will control default stdio settings.
* dtable.cc (dtable::init_std_file_from_handle): Allow __fmode to force
binmode/textmode settings. Default pipes to binmode.
* dlfcn.cc (check_access): Eliminate.
(check_path_access): Use passed in path_conv buf.
(get_full_path_of_dll): Use passed in name buf to avoid a static. Rip out most
of the path checking since LoadLibrary will do all of this automatically.
(dlopen): Set errno when appropriate (may not be compliant?).
* environ.cc (posify): Don't pass in "native" path if it seems to actually be
posix.
* fhandler.h (fhandler_dev_clipboard): Extend to support writing.
* fhandler_clipboard.cc (fhandler_dev_clipboard::fhandler_dev_clipboard):
Initialize new fields. Open clipboard here.
(fhandler_dev_clipboard::dup): New method.
(fhandler_dev_clipboard::open): Accomodate new fields. Register clipboard
here, if appropriate.
(set_clipboard): New function. Moves buffer to clipboard.
(fhandler_dev_clipboard::write): Truly implement clipboard writing.
(fhandler_dev_clipboard::read): Reimplement to allow successive reads.
(fhandler_dev_clipboard::lseek): Truly implement seeks in clipboard.
(fhandler_dev_clipboard::close): Clear out new fields. Support sequential
reads and sequential writes. Support for binary data via a native clipboard
format.
Alexandre Oliva [Thu, 22 Mar 2001 18:17:54 +0000 (18:17 +0000)]
Re-installed:
2001-01-02 Laurynas Biveinis <lauras@softhome.net>
* ltcf-c.sh: Clear ac_cv_prog_cc_pic for DJGPP. Do not add
'-DPIC' to ac_cv_prog_cc_pic for DJGPP.
* ltcf-cxx.sh: Likewise.
* ltcf-gcj.sh: Likewise.
* autoload.cc (kernel32_init): New function for kernel32 autoload
initialization.
(SignalObjectAndWait): Add conditional load of this function when it is
available.
Jeff Johnston [Wed, 21 Mar 2001 21:47:31 +0000 (21:47 +0000)]
2001-03-21 Egor Duda <deo@logos-m.ru>
Allow building internal stubs for non-reentrant syscalls
if target provides its own malloc
* libc/reent/reent.c (errno): Move definition here.
* libc/reent/sbrkr.c: From here.
* sched.cc: New file. Implement sched*.
* include/sched.h: New file. User land includes for sched*.
* Makefile.in: Add sched.o
* cygwin.din: Add exports for sched*.
* libc/include/sys/types.h (BSD int typedefs): Guard with _BSDTYPES_DEFINED
rather than _WINSOCK_H.
(fd_set): Add !defined __USE_W32_SOCKETS to guard; define _SYS_TYPES_FD_SET.
* libc/include/sys/unistd.h (gethostname): Don't declare if defined
(_WINSOCK_H) || defined (__USE_W32_SOCKETS).
* include/winsock.h (_SYS_TYPES_H macro guard for int types): Remove; use only
_BSDTYPES_DEFINED macro now defined in newlib sys/types.h.
(SYS_TYPES_H macro guard for fd_set): Replace with_SYS_TYPES_FD_SET macro now
defined in newlib sys/types.h. Emit warning if defined.
* include/winsock2.h: Ditto.
* include/windows.h (Win32_Winsock): Replace with new macros __USE_W32_SOCKETS
and warn of deprecation.
Jim Blandy [Tue, 20 Mar 2001 18:22:38 +0000 (18:22 +0000)]
* libiberty/cp-demangle.c (struct demangling_def): New fields:
is_constructor and is_destructor.
(demangling_new): Initialize them.
(demangle_ctor_dtor_name): Set them, if we detect a constructor
or destructor.
(demangle_v3_with_details, is_gnu_v3_mangled_ctor,
is_gnu_v3_mangled_dtor): New functions.
* include/demangle.h (enum gnu_v3_constructor_kinds,
is_gnu_v3_mangled_ctor, enum gnu_v3_destructor_kinds,
is_gnu_v3_mangled_dtor): New declarations.
* exceptions.cc (interruptible): Update debugging output.
(setup_handler): Ensure that wait_sig loop wakes up when we punt on sending a
signal.
* poll.cc (poll): Add signal guard here.
Corinna Vinschen [Mon, 19 Mar 2001 11:02:41 +0000 (11:02 +0000)]
* syscalls.cc (check_posix_perm): New static function.
(fpathconf): Add _PC_POSIX_PERMISSIONS and _PC_POSIX_SECURITY
support.
(pathconf): Ditto.
* include/cygwin/version.h: Bump API minor number to 37.
* external.cc (fillout_pinfo): Match windows pid, as well as cygwin pid when
passed in pid. Don't prematurely break when searching for a pid.
* thread.h (_winsup_t): Eliminate unneeded field.
* dir.cc (readdir): Use strcasematch for consistency.
* path.cc (symlink_info): Eliminate known_suffix.
(path_conv::check): Always copy ext_here to end of buffer, if found.
(suffix_scan): Eliminate ext_here, add suffixes_start.
(suffix_scan::has): Eliminate an argument. Reorganize. Always return pointer
to end of input path.
(suffix_scan::next): Take a second pass through the suffix list looking for
.lnk.
(symlink_info::check): Eliminate known_suffix usage.
* path.cc: Translate scan states from defines to enums.
(suffix_scan): Rename state to nextstate for clarity.
(lnk_match): Change to allow multiple states to indicate that a .lnk has been
matched.
(suffix_scan::has): Eliminate a goto. Handle .lnk as a special case, since a
.lnk may also need to be tacked on the end of a .lnk.
(suffix_scan::next): Don't increment next state. Set it specifically.
Recognize new .lnk states.
* cygwin.din: Export the new functions.
* pthread.cc (pthread_cond_*): Add wrapper functions that call __pthread_cond*
functions.
* thread.cc (__pthread_cond_*): Implement the pthread_cond* functions.
* thread.h: Add new class entries and prototypes for __pthread_cond* functions.
* include/pthread.h: user land header prototypes for pthread_cond* functions
and related defines.
Egor Duda [Mon, 12 Mar 2001 21:27:42 +0000 (21:27 +0000)]
* fhandler.h (fhandler_termios::fixup_after_exec): New function.
* fhandler.cc (fhandler_termios::fixup_after_fork): New function.
Fixup output handle.
* fhandler_tty.cc (fhandler_tty_common::fixup_after_fork): Output
handle is now fixed up in fhandler_termios::fixup_after_fork().
Egor Duda [Mon, 12 Mar 2001 20:39:40 +0000 (20:39 +0000)]
* fhandler.h (fhandler_termios::fhandler_termios): Enable fixup
after fork.
* fhandler_console.cc (fhandler_console::fhandler_console): Fixup
after fork is now enabled in the base class constructor.
Earnie Boyd [Mon, 12 Mar 2001 19:26:16 +0000 (19:26 +0000)]
* include/commctrl.h (TBSTYLE_FLAT): New definition.
(TB_GETBUTTONSIZE): Ditto.
(TCS_HOTTRACK): Ditto.
Thanks to: Chris Hansen <popeofpop@softhome.net>
* autoload.cc (noload): Use proper method for multiline strings or newer gcc's
complain.
* exceptions.cc (unused_sig_wrapper): Ditto.
* fhandler.h (fhandler_base): Make get_io_handle and friends return self.
* fhandler_tty.cc (fhandler_pty_common::close_on_exec): Accomodate DEBUGGING
flag to avoid spurious warnings when inheritance is set.
* shortcut.c (PATH_ALL_EXEC): Add parentheses to avoid a compiler warning.
* exceptions.cc (setup_handler): Clarify debugging message.
* sigproc.cc (proc_subproc): Remove PROC_CHILDSTOPPED test. It is handled by
normal PROC_CLEARWAIT case.
(wait_sig): Eliminate "dispatched" tracking. Remove __SIGCHILDSTOPPED test.
Decrement counter again before jumping out of InterlockedDecrement loop so that
subsequent InterlockedIncrement will keep the counter at the correctly
decremented value and also detect when there are pending signals.
* sigproc.h: Remove __SIGCHILDSTOPPED element.
(procstuff): Remove PROC_CHILDSTOPPED element.
* syscalls.cc (_rename): Set errno to ENOENT when an old path doesn't exist
(from Kazuhiro Fujieda <fujieda@jaist.ac.jp>). Also set EACCES when directory
is not writable.
* syscalls.cc (_read): Change definition to return ssize_t to be consistent
with read.
(_write): Change definition to return ssize_t to be consistent with write.