* autoload.cc (NtQueryEaFile): Define.
(NtSetEaFile): Define.
* fhandler.cc (fhandler_base::open): Use appropriate open flags
in query case when allow_ntea is set.
* ntdll.h (struct _FILE_GET_EA_INFORMATION): Define.
(struct _FILE_FULL_EA_INFORMATION): Define.
(NtQueryEaFile): Declare.
(NtSetEaFile): Declare.
* ntea.cc (read_ea): Rename from NTReadEA and rewrite using
NtQueryEaFile.
(write_ea): Rename from NTWriteEA and rewrite using NtSetEaFile.
* path.cc (get_symlink_ea): Make static. Add handle parameter to
accomodate new read_ea call.
(set_symlink_ea): Make static. Add handle parameter to accomodate new
write_ea call.
(symlink_worker): Call set_symlink_ea while file is still open.
(symlink_info::check): Call get_symlink_ea after file has been opened.
* security.cc (get_file_attribute): Accomodate new read_ea call.
(set_file_attribute): Accomodate new write_ea call.
* security.h (read_ea): Change declaration accordingly.
(write_ea): Ditto.
* fhandler.h (class dev_console): Add `metabit' indicating the
current meta key mode.
* fhandler_console.cc (fhandler_console::read): Set the top bit of
the character if metabit is true.
* fhandler_console.cc (fhandler_console::ioctl): Implement
KDGKBMETA and KDSKBMETA commands.
* fhandler_tty.cc (process_ioctl): Support KDSKBMETA.
(fhandler_tty_slave::ioctl): Send KDGKBMETA and KDSKBMETA to the
master.
* include/cygwin/kd.h: New file for the meta key mode.
* include/sys/kd.h: New file.
Corinna Vinschen [Mon, 26 Jun 2006 12:12:11 +0000 (12:12 +0000)]
Revert patches from 2005-10-22 and 2006-06-14 to use event driven
accept and connect back to using select:
* fhandler.h (class fhandler_socket): Remove accept_mtx.
* fhandler_socket.cc (fhandler_socket::fhandler_socket): Drop
initializing accept_mtx.
(fhandler_socket::accept): Drop event handling.
(fhandler_socket.cc (fhandler_socket::connect): Ditto.
(fhandler_socket::dup): Drop accept_mtx handling.
(fhandler_socket::listen): Ditto.
(fhandler_socket::prepare): Ditto.
(fhandler_socket::release): Ditto.
(fhandler_socket::close): Ditto.
* net.cc (cygwin_accept): Revert to calling cygwin_select to
implement interuptible accept.
(cygwin_connect): Ditto for connect.
* fhandler_fifo.cc (fhandler_fifo::open): Release process lock and grab a
system-wide mutex to prevent a deadlock and a race.
* sync.h (lock_process): Make fhandler_fifo a friend.
* smallprint.c (__small_vsprintf): Cosmetic change.
Jeff Johnston [Thu, 22 Jun 2006 17:59:52 +0000 (17:59 +0000)]
2006-06-22 Jeff Johnston <jjohnstn@redhat.com>
* libc/stdlib/Makefile.am: Add new gdtoa routines.
* libc/stdlib/Makefile.in: Regenerated.
* libc/stdlib/gd_qnan.h: New file.
* libc/stdlib/gdtoa-gethex.c: Ditto.
* libc/stdlib/gdtoa-hexnan.c: Ditto.
* libc/stdlib/gdtoa.h: Ditto.
* libc/stdlib/mprec.c: Add new helper routines needed by
the new gdtoa code.
* libc/stdlib/mprec.h: Integrate some defines and prototypes
used by gdtoa routines here.
* libc/stdlib/strtod.c: Rebased on David M. Gay's gdtoa-strtod.c
which adds C99 support such as nan, inf, and hexadecimal input
format.
David Ayers [Tue, 20 Jun 2006 08:45:35 +0000 (08:45 +0000)]
2006-06-20 David Ayers <d.ayers@inode.at>
PR bootstrap/28072
* configure.in: Add target-boehm-gc to noconfigdirs depending on
whether target-libjava is being configured instead of whether the
java front end is enabled.
* configure: Regenerate.
Mark Shinwell [Thu, 15 Jun 2006 11:03:01 +0000 (11:03 +0000)]
* include/elf/arm.h: Correct names of R_ARM_LDC_G{0,1,2}
to R_ARM_LDC_SB_G{0,1,2} respectively.
bfd/
* bfd-in2.h: Regenerate.
* elf32-arm.c (R_ARM_ALU_PC_G0_NC, R_ARM_ALU_PC_G0,
R_ARM_ALU_PC_G1_NC, R_ARM_ALU_PC_G1, R_ARM_ALU_PC_G2,
R_ARM_LDR_PC_G1, R_ARM_LDR_PC_G2, R_ARM_LDRS_PC_G0,
R_ARM_LDRS_PC_G1, R_ARM_LDRS_PC_G2, R_ARM_LDC_PC_G0,
R_ARM_LDC_PC_G1, R_ARM_LDC_PC_G2, R_ARM_ALU_SB_G0_NC,
R_ARM_ALU_SB_G0, R_ARM_ALU_SB_G1_NC, R_ARM_ALU_SB_G1,
R_ARM_ALU_SB_G2, R_ARM_LDR_SB_G0, R_ARM_LDR_SB_G1,
R_ARM_LDR_SB_G2, R_ARM_LDRS_SB_G0, R_ARM_LDRS_SB_G1,
R_ARM_LDRS_SB_G2, R_ARM_LDC_SB_G0, R_ARM_LDC_SB_G1,
R_ARM_LDC_SB_G2): New relocation types.
(R_ARM_PC13): Rename to AAELF name R_ARM_LDR_PC_G0 and
adjust HOWTO entry to be consistent with R_ARM_LDR_PC_G1
and friends.
(elf32_arm_howto_table_3): Delete; contents merged into
elf32_arm_howto_table_2.
(elf32_arm_howto_from_type): Adjust correspondingly.
(elf32_arm_reloc_map): Extend with the above relocations.
(calculate_group_reloc_mask): New function.
(identify_add_or_sub): New function.
(elf32_arm_final_link_relocate): Support for the above
relocations.
* reloc.c: Add enumeration entries for BFD_RELOC_ARM_...
codes to correspond to the above relocations.
gas/
* config/tc-arm.c (enum parse_operand_result): New.
(struct group_reloc_table_entry): New.
(enum group_reloc_type): New.
(group_reloc_table): New array.
(find_group_reloc_table_entry): New function.
(parse_shifter_operand_group_reloc): New function.
(parse_address_main): New function, incorporating code
from the old parse_address function. To be used via...
(parse_address): wrapper for parse_address_main; and
(parse_address_group_reloc): new function, likewise.
(enum operand_parse_code): New codes OP_SHG, OP_ADDRGLDR,
OP_ADDRGLDRS, OP_ADDRGLDC.
(parse_operands): Support for these new operand codes.
New macro po_misc_or_fail_no_backtrack.
(encode_arm_cp_address): Preserve group relocations.
(insns): Modify to use the above operand codes where group
relocations are permitted.
(md_apply_fix): Handle the group relocations
ALU_PC_G0_NC through LDC_SB_G2.
(tc_gen_reloc): Likewise.
(arm_force_relocation): Leave group relocations for the linker.
(arm_fix_adjustable): Likewise.
gas/testsuite/
* gas/arm/group-reloc-alu.d: New test.
* gas/arm/group-reloc-alu-encoding-bad.d: New test.
* gas/arm/group-reloc-alu-encoding-bad.l: New test.
* gas/arm/group-reloc-alu-encoding-bad.s: New test.
* gas/arm/group-reloc-alu-parsing-bad.d: New test.
* gas/arm/group-reloc-alu-parsing-bad.l: New test.
* gas/arm/group-reloc-alu-parsing-bad.s: New test.
* gas/arm/group-reloc-alu.s: New test.
* gas/arm/group-reloc-ldc.d: New test.
* gas/arm/group-reloc-ldc-encoding-bad.d: New test.
* gas/arm/group-reloc-ldc-encoding-bad.l: New test.
* gas/arm/group-reloc-ldc-encoding-bad.s: New test.
* gas/arm/group-reloc-ldc-parsing-bad.d: New test.
* gas/arm/group-reloc-ldc-parsing-bad.l: New test.
* gas/arm/group-reloc-ldc-parsing-bad.s: New test.
* gas/arm/group-reloc-ldc.s: New test.
* gas/arm/group-reloc-ldr.d: New test.
* gas/arm/group-reloc-ldr-encoding-bad.d: New test.
* gas/arm/group-reloc-ldr-encoding-bad.l: New test.
* gas/arm/group-reloc-ldr-encoding-bad.s: New test.
* gas/arm/group-reloc-ldr-parsing-bad.d: New test.
* gas/arm/group-reloc-ldr-parsing-bad.l: New test.
* gas/arm/group-reloc-ldr-parsing-bad.s: New test.
* gas/arm/group-reloc-ldr.s: New test.
* gas/arm/group-reloc-ldrs.d: New test.
* gas/arm/group-reloc-ldrs-encoding-bad.d: New test.
* gas/arm/group-reloc-ldrs-encoding-bad.l: New test.
* gas/arm/group-reloc-ldrs-encoding-bad.s: New test.
* gas/arm/group-reloc-ldrs-parsing-bad.d: New test.
* gas/arm/group-reloc-ldrs-parsing-bad.l: New test.
* gas/arm/group-reloc-ldrs-parsing-bad.s: New test.
* gas/arm/group-reloc-ldrs.s: New test.
ld/testsuite/
* ld-arm/group-relocs-alu-bad.d: New test.
* ld-arm/group-relocs-alu-bad.s: New test.
* ld-arm/group-relocs.d: New test.
* ld-arm/group-relocs-ldc-bad.d: New test.
* ld-arm/group-relocs-ldc-bad.s: New test.
* ld-arm/group-relocs-ldr-bad.d: New test.
* ld-arm/group-relocs-ldr-bad.s: New test.
* ld-arm/group-relocs-ldrs-bad.d: New test.
* ld-arm/group-relocs-ldrs-bad.s: New test.
* ld-arm/group-relocs.s: New test.
* ld-arm/arm-elf.exp: Wire in new tests.
Jeff Johnston [Wed, 14 Jun 2006 20:49:11 +0000 (20:49 +0000)]
2006-06-14 Jeff Johnston <jjohnstn@redhat.com>
* libc/include/stdio.h: Add new reentrant I/O prototypes for
read/write functions. Change getc/putc macros to have reentrant underlying
macros/functions. This includes __sgetc_raw_r, __sgetc_r, and __sputc_r.
* libc/stdio/fgetc.c: Fix and/or add reentrant version to call
new reentrant I/O functions/macros for reading/writing.
* libc/stdio/fgets.c: Ditto.
* libc/stdio/fputc.c: Ditto.
* libc/stdio/fputs.c: Ditto.
* libc/stdio/fread.c: Ditto.
* libc/stdio/fseek.c: Ditto.
* libc/stdio64/fseeko64.c: Ditto.
* libc/stdio/fwrite.c: Ditto.
* libc/stdio/getc.c: Ditto.
* libc/stdio/getc_u.c: Ditto.
* libc/stdio/getchar.c: Ditto.
* libc/stdio/getchar_u.c: Ditto.
* libc/stdio/putc.c: Ditto.
* libc/stdio/putc_u.c: Ditto.
* libc/stdio/putchar.c: Ditto.
* libc/stdio/puts.c: Ditto.
* libc/stdio/vfprintf.c: Ditto.
* libc/stdio/vfscanf.c: Ditto.
* libc/stdio/fvwrite.c: Change __sfvwrite into reentrant __sfvwrite_r.
Change all previous callers of __sfvwrite. Set errno to EBADF and
set error flag on if attempt is made to write to file that does not
allow writing.
* libc/stdio/fvwrite.h: Fix new reentrant prototypes.
* libc/stdio/local.h: Ditto.
* libc/stdio/refill.c: Turn __srefill into reentrant __srefill_r.
Set errno to EBADF and the error flag on if attempt is made to
read unreadable file. Change all previous callers of __srefill.
* libc/stdio/rget.c
* libc/stdio/wbuf.c: Turn __swbuf into reentrant __swbuf_r. Change
all previous callers of __swbuf.
* libc/sys/linux/machine/i386/huge_val.h: Ifdef out file contents since
huge value macros are already defined correctly for i386 by <math.h>.
Corinna Vinschen [Wed, 14 Jun 2006 20:19:10 +0000 (20:19 +0000)]
* fhandler.h (class fhandler_socket): Add private mutex handle
accept_mtx.
* fhandler_socket.cc (fhandler_socket::fhandler_socket): Initialize
accept_mtx to NULL.
(fhandler_socket::dup): Duplicate accept_mtx, if available.
(fhandler_socket::listen): Create accept_mtx before trying to listen.
(fhandler_socket::prepare): Wait for accept_mtx if available to
serialize accepts on the same socket.
(fhandler_socket::release): Release accept_mtx.
(fhandler_socket::close): Close accept_mtx on successful closesocket.
Chris Sutcliffe [Tue, 13 Jun 2006 17:32:01 +0000 (17:32 +0000)]
2006-06-13 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* lib/Makefile.in: Added extras-uuid as an object and source.
* lib/uuid.c (IID_IClientSiteHandler, IID_IContinue, IID_IHttpNegotiate,
IID_IPersistMoniker, IID_IServerHandler, IID_ITargetEmbedding,
IID_ITargetFrame, IID_ITypeComp, IID_IUrlHistoryStg, IID_IWinInetHttpInfo,
IID_IWinInetInfo, IID_IEnumSTATPROPSETSTG, IID_IEnumSTATPROPSTG,
IID_IEnumSTATURL): Remove. Moved to extras-uuid.c.
* lib/extras-uuid.c: New file.
Thank you to Julien Lecomte (julienlecomte at users dot sourceforge dot
net).
Corinna Vinschen [Mon, 12 Jun 2006 14:25:05 +0000 (14:25 +0000)]
* include/sys/wait.h: Move definition of wait constants from here...
* include/cygwin/wait.h: ...to here. New file.
* include/cygwin/stdlib.h: Include cygwin/wait.h to conform with SUSv3.
Danny Smith [Mon, 12 Jun 2006 00:55:06 +0000 (00:55 +0000)]
[mingw-Bugs-1424461]
*include/imagehlp.h: Comment out IN, OUT and OPTIONAL,
throughout.
*include/rpcdce.h: Don't define IN, OUT or OPTIONAL if
_NO_W32_PSEUDO_MODIFIERS.
*include/rpcnsi.h: Comment out IN, OUT and OPTIONAL,
throughout.
*include/rpcnsip.h: Likewise.
*include/windef.h: Don't define IN, OUT or OPTIONAL
if _NO_W32_PSEUDO_MODIFIERS.
*include/ddk/batclass.h: Comment out IN, OUT and OPTIONAL,
throughout.
*include/ddk/cfgmgr32.h: Likewise.
*include/ddk/ddkmapi.h: Likewise.
*include/ddk/hidclass.h: Likewise.
*include/ddk/hidpi.h: Likewise.
*include/ddk/kbdmou.h: Likewise.
*include/ddk/mcd.h: Likewise.
*include/ddk/miniport.h: Likewise.
*include/ddk/minitape.h: Likewise.
*include/ddk/ndis.h: Likewise.
*include/ddk/ndistapi.h: Likewise.
*include/ddk/ndiswan.h: Likewise.
*include/ddk/ntapi.h: Likewise.
*include/ddk/ntdd8042.h: Likewise.
*include/ddk/ntddpcm.h: Likewise.
*include/ddk/ntifs.h: Likewise.
*include/ddk/ntpoapi.h: Likewise.
*include/ddk/parallel.h: Likewise.
*include/ddk/pfhook.h: Likewise.
*include/ddk/scsiwmi.h: Likewise.
*include/ddk/smbus.h: Likewise.
*include/ddk/srb.h: Likewise.
*include/ddk/storport.h: Likewise.
*include/ddk/tdikrnl.h: Likewise.
*include/ddk/upssvc.h: Likewise.
*include/ddk/usbcamdi.h: Likewise.
*include/ddk/usbscan.h: Likewise.
*include/ddk/video.h: Likewise.
*include/ddk/videoagp.h: Likewise.
*include/ddk/win2k.h: Likewise.
*include/ddk/winddi.h: Likewise.
*include/ddk/winddk.h: Don't define IN, OUT or OPTIONAL
if _NO_W32_PSEUDO_MODIFIERS.
Comment out IN, OUT and OPTIONAL, throughout.
*include/ddk/winnt4.h: Comment out IN, OUT and OPTIONAL,
throughout.
*include/ddk/ws2san.h: Likewise.
Chris Sutcliffe [Sat, 10 Jun 2006 12:31:17 +0000 (12:31 +0000)]
2006-06-10 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* lib/Makefile.in: Added urlmon-uuid and hlink-uuid as sources and
objects.
* lib/uuid.c (IID_IAuthenticate, IID_IBindHost, IID_IBindProtocol,
IID_IBindStatusCallback, IID_IBindStatusCallbackMsg, IID_IBinding,
IID_IHlink, IID_IHlinkBrowseContext, IID_IHlinkFrame, IID_IHlinkSite,
IID_IHlinkTarget): Remove. Moved to new files.
* lib/urlmon-uuid.c: New file.
* lib/hlink-uuid.c: New file.
Chris Sutcliffe [Sat, 10 Jun 2006 11:45:41 +0000 (11:45 +0000)]
2006-06-10 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* lib/Makefile.in: Added ativscp-uuid as source and object.
* lib/uuid.c (IID_IActiveScript, IID_IActiveScriptError,
IID_IActiveScriptParse, IID_IActiveScriptSite,
IID_IActiveScriptSiteWindow): Remove. Moved to ativscp-uuid.c.
* lib/ativscp-uuid.c: New file.
Carlos O'Donell [Wed, 7 Jun 2006 22:33:16 +0000 (22:33 +0000)]
2006-06-07 Carlos O'Donell <carlos@codesourcery.com>
Sync from gcc:
2006-06-06 David Ayers <d.ayers@inode.at>
PR libobjc/13946
* Makefile.def: Add dependencies for libobjc which boehm-gc.
* Makefile.in: Regenerate.
* configure.in: Add --enable-objc-gc at toplevel and have it
enable boehm-gc for Objective-C.
Remove target-boehm-gc from libgcj.
Add target-boehm-gc to target_libraries.
Add target-boehm-gc to noconfigdirs where ${libgcj}
is specified.
Assert that boehm-gc is supported when requested for Objective-C.
Only build boehm-gc if needed either for Java or Objective-C.
* configure: Regenerate.
2006-06-05 Paolo Bonzini <bonzini@gnu.org>
PR 27674
* Makefile.tpl (configure-[+prefix+][+module+],
all-[+prefix+][+module+]): Depend on stage_current if bootstrapping.
Remove rule to unstage bootstrapped modules.
(stage_current): New.
* Makefile.in: Regenerate.
2006-05-20 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
Andreas Tobler <a.tobler@schweiz.ch>
* configure.in: Enable libgcj for hppa*-hp-hpux11*.
* configure: Rebuilt.
Revert
2006-01-31 Richard Guenther <rguenther@suse.de>
Paolo Bonzini <bonzini@gnu.org>
Thiemo Seufer [Mon, 5 Jun 2006 16:28:36 +0000 (16:28 +0000)]
[ gas/ChangeLog ]
* config/tc-mips.c (macro_build): Use INSERT_OPERAND wherew
appropriate.
(mips16_macro_build): Use MIPS16_INSERT_OPERAND where appropriate.
(mips_ip): Make overflowed/underflowed constant arguments in DSP
and MT instructions a fatal error. Use INSERT_OPERAND where
appropriate. Improve warnings for break and wait code overflows.
Use symbolic constant of OP_MASK_COPZ.
(mips16_ip): Use MIPS16_INSERT_OPERAND where appropriate.
Chris Sutcliffe [Sun, 4 Jun 2006 15:37:31 +0000 (15:37 +0000)]
2006-06-04 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* lib/Makefile.in: Add unknwn-uuid and servprov-uuid as sources and
objects.
* lib/uuid.c (IID_IUnknown, IID_IClassFactory, IID_IServiceProvider):
Remove. Moved to unknwn-uuid and servprov-uuid.
* lib/unknwn-uuid.c: New file.
* lib/servprov-uuid.c: New file.
* cygthread.cc (cygthread::terminate_thread): In debugging output, use name of
thread being terminated rather than thread doing terminating.
* fhandler.h (fhandler_pty_master::slave): Delete.
(fhandler_pty_master::get_unit): Ditto.
(fhandler_pty_master::setup): Change argument declaration to accommodate new
usage.
* fhandler_tty.cc (fhandler_tty_master::init): Remove obsolete slave
assignment. Pass argument to setup indicating that this is a tty.
(fhandler_tty_slave::open): Use dev() method rather than referencing pc.dev
directly.
(fhandler_pty_master::open): Don't create archetype based on ptym device
number. Set device number to use DEV_TTYM_MAJOR and tty number. Pass argument
to setup indicating that this is a pty.
(fhandler_pty_master::setup): Change single argument to a flag indicating
whether we're creating a pty and use appropriately. Calculate 't' variable
here rather than in caller.
* fhandler_dsp.cc (fhandler_dev_dsp::open): Use dev() method rather than
referencing pc.dev directly.
* dcrt0.cc (dll_crt0_0): Call tty_list::init_session here.
(dll_crt0_1): Reflect renaming from tty_init to tty::init_session.
(do_exit): Reflect moving of tty_terminate into tty_list.
* exceptions.cc (events_init): Move tty_mutex stuff elsewhere.
* fhandler_console.cc (set_console_title): Use lock_ttys class.
* fhandler_termios.cc (fhandler_termios::bg_check): Make debug output more
accurate.
* fhandler_tty.cc (fhandler_tty_slave::open): Reflect move of attach_tty into
tty_list class. Don't attempt to grab master end of pty if master doesn't
exist.
(fhandler_pty_master::open): Reflect move of allocate_tty into tty_list class.
Use lock_ttys::release to release mutex. Improve debugging output.
(fhandler_pty_master::setup): Remove if 0'ed block. Fix argument to
SetNamedPipeHandleState.
* pinfo.cc (_pinfo::set_ctty): Lock ttys before setting sid/pgid. Improve
debugging. Add temporary debugging.
* tty.cc (tty_list::init_session): New function.
(tty::init_session): Rename from tty_init. Reflect move of attach_tty to
tty_list class.
(tty::create_master): Rename from create_tty_master.
(tty_list::attach): Rename from attach_tty. Reflect renaming of connect_tty to
connect. Ditto for allocate_tty.
(tty_terminate): Delete.
(tty_list::terminate): Subsume tty_terminate. Use lock_ttys rather than
manipulating mutex directly.
(tty_list::allocate): Rename from allocate_tty. Use lock_ttys rather than
manipulating mutex directly. Don't set sid here since linux apparently doesn't
do this. Reflect move of create_tty_master into tty.
(lock_ttys::lock_ttys): Define new constructor.
(lock_ttys::release): New function.
* tty.h (tty::exists): Return false immediately if !master_pid.
(tty::set_master_closed): Define new function.
(tty::create_master): Ditto.
(tty::init_session): Ditto.
(tty_list::mutex): New field.
(tty_list::allocate): Define new function.
(tty_list::connect): Ditto.
(tty_list::attach): Ditto.
(tty_list::init_session): Ditto.
(lock_ttys): New class.
(tty_init): Delete declaration.
(tty_terminate): Ditto.
(attach_tty): Ditto.
(create_tty_master): Ditto.
* fhandler_tty.cc (fhandler_pty_master::close): Don't close handles if we don't
own them.
(fhandler_pty_master::setup): Make sure that original handle is closed when
changing inheritance.
(fhandler_pty_master::fixup_after_fork): Set from_master/to_master to arch
value always.
(fhandler_pty_master::fixup_after_exec): Clear from_master/to_master when
close_on_exec.
* cygheap.cc (init_cygheap::close_ctty): Remove obsolete code.
* dcrt0.cc (child_info_spawn::handle_spawn): Signal ready after we've run
fixup_after_exec.
* dtable.cc (dtable::fixup_after_exec): Add debugging output.
* fhandler_tty.cc (fhandler_pty_master::doecho): Use class version of
to_master.
(fhandler_tty_common::close): Remove obsolete code.
(fhandler_tty_slave::fixup_after_exec): Don't close, since this is done in
dtable's fixup_after_exec. (revisit later?)
(fhandler_pty_master::fixup_after_exec): Ditto.
* fhandler.cc (fhandler_base::fixup_after_exec): Declare here.
* fhandler.h (fhandler_base::fixup_after_exec): Make non-inline.
(fhandler_termios::fixup_after_fork): Delete declaration.
(fhandler_termios::fixup_after_exec): Ditto.
(fhandler_tty_common::inuse): Remove.
(fhandler_tty_common::dup): Delete declaration.
(fhandler_tty_common::fixup_after_fork): Ditto.
(fhandler_tty_slave::fixup_after_exec): Declare new function.
(fhandler_pty_master::dwProcessId): New variable.
(fhandler_pty_master::from_master): Ditto.
(fhandler_pty_master::to_master): Ditto.
(fhandler_pty_master::setup): New function.
(fhandler_pty_master::fixup_after_fork): Ditto.
(fhandler_pty_master::fixup_after_exec): Ditto.
* fhandler_termios.cc (fhandler_termios::fixup_after_exec): Delete definition.
(fhandler_termios::fixup_after_fork): Ditto.
* fhandler_tty.cc (fhandler_tty_master::init): Use fhandler_pty_master setup
function rather than obsolete tty::common_init. Delete obsolete inuse setting.
(fhandler_tty_slave::fhandler_tty_slave): Set inuse to NULL here.
(fhandler_tty_slave::open): Change debugging output for clarity. Check for
different things when doing a sanity check on the tty. Reflect the fact that
master_pid now is the cygwin pid rather than the windows pid. Use "arch"
rather than "archetype" for consistency.
(fhandler_tty_slave::close): Close inuse here.
(fhandler_tty_slave::dup): Remove old if 0'ed code.
(fhandler_pty_master::dup): New function. Handles pty master archetype.
(fhandler_pty_master::fhandler_pty_master): Zero pty_master specific fields.
(fhandler_pty_master::open): Implement using archetypes, similar to slave. Use
fhandler_pty_master setup function rather than obsolete tty::common_init.
Don't set inuse.
(fhandler_tty_common::close): Don't deal with inuse. Delete old if 0'ed code.
(fhandler_pty_master::close): Implement using archetypes. Close from_master
and to_master.
(fhandler_tty_common::set_close_on_exec): Just set close_on_exec flag here
since everything uses archetypes now.
(fhandler_tty_common::fixup_after_fork): Delete definition.
(fhandler_tty_slave::fixup_after_exec): Define new function.
(fhandler_pty_master::setup): New function, derived from tty::common_init.
(fhandler_pty_master::fixup_after_fork): New function.
(shared_info.h): Reset SHARED_INFO_CB to reflect new tty size.
* tty.cc (tty_list::terminate): Close individual handles from tty_master.
(tty::master_alive): Delete.
(tty::make_pipes): Ditto.
(tty::common_init): Ditto.
* tty.h (tty::from_slave): Delete.
(tty::to_slave): Ditto.
(tty::common_init): Delete declaration.
(tty::make_pipes): Ditto.
(tty::master_pid): Define as pid_t since it is now a cygwin pid.