]> sourceware.org Git - newlib-cygwin.git/log
newlib-cygwin.git
12 years ago* sync.cc: Fix comment.
Christopher Faylor [Tue, 29 Nov 2011 17:26:57 +0000 (17:26 +0000)]
* sync.cc: Fix comment.
* dll_init.cc (dll_list::reserve_space): Use %p rather than %lx to show
reserved space.

12 years ago* sigproc.cc (remove_proc): Don't terminate the currently executing thread.
Christopher Faylor [Tue, 29 Nov 2011 15:34:49 +0000 (15:34 +0000)]
* sigproc.cc (remove_proc): Don't terminate the currently executing thread.

12 years ago[libgloss]
DJ Delorie [Tue, 29 Nov 2011 06:33:49 +0000 (06:33 +0000)]
[libgloss]
* configure.in: Add rl78.
* configure: Regenerate.
* rl78: New directory

[newlib]
* configure.host: Add rl78.
* libc/include/machine/ieeefp.h: Add rl78 support.
* libc/include/machine/setjmp.h: Add rl78 support.
* libc/machine/configure.in: Add rl78.
* libc/machine/rl78: New directory.

12 years agofix older description
Christopher Faylor [Tue, 29 Nov 2011 05:38:12 +0000 (05:38 +0000)]
fix older description

12 years ago * locale.cc (print_locale_with_codeset): Fetch Windows path as UNICODE
Corinna Vinschen [Mon, 28 Nov 2011 17:58:48 +0000 (17:58 +0000)]
* locale.cc (print_locale_with_codeset): Fetch Windows path as UNICODE
path and convert that to POSIX.

12 years ago * external.cc (fillout_pinfo): Store program name as POSIX path in
Corinna Vinschen [Mon, 28 Nov 2011 17:53:18 +0000 (17:53 +0000)]
* external.cc (fillout_pinfo): Store program name as POSIX path in
ep.progname_long.

12 years ago * ps.cc: Remove all Win 9x considerations. Use psapi functions
Corinna Vinschen [Mon, 28 Nov 2011 17:49:56 +0000 (17:49 +0000)]
* ps.cc: Remove all Win 9x considerations.  Use psapi functions
directly.  Drop support for older Cygwin DLLs.  Just use progname_long
as is since it's already a POSIX path now.  Rename "tty" to "pty" as in
the Cygwin DLL.  Call setlocale to make sure wcstombs does the right
thing according to the current locale.
* Makefile.in (ps.exe): Link against psapi.dll.

12 years ago * pinfo.cc (pinfo::exit): Call TerminateProcess to avoid potential
Corinna Vinschen [Mon, 28 Nov 2011 16:00:07 +0000 (16:00 +0000)]
* pinfo.cc (pinfo::exit): Call TerminateProcess to avoid potential
busy loop in ntdll.dll when calling ExitProcess. Only call ExitProcess
as a fallback.

12 years ago* init.cc (dll_entry): Revert previous change since it caused inexplicable fork
Christopher Faylor [Sun, 27 Nov 2011 19:00:33 +0000 (19:00 +0000)]
* init.cc (dll_entry): Revert previous change since it caused inexplicable fork
problems.

12 years agoClean up DIRENT errno handling; make it more POSIX conformant.
Keith Marshall [Sat, 26 Nov 2011 22:12:51 +0000 (22:12 +0000)]
Clean up DIRENT errno handling; make it more POSIX conformant.

12 years ago* init.cc (remove): Don't bother calling through thread removal cleanup if we
Christopher Faylor [Sat, 26 Nov 2011 19:20:13 +0000 (19:20 +0000)]
* init.cc (remove): Don't bother calling through thread removal cleanup if we
are exiting.

12 years ago* exceptions.cc (stackdump): Make global.
Christopher Faylor [Sat, 26 Nov 2011 19:14:22 +0000 (19:14 +0000)]
* exceptions.cc (stackdump): Make global.
(signal_exit): Move to sigproc.cc.
* sigproc.cc (signal_exit): Move here.  Declare stackdump extern.  Set
my_sendsig to indicate that signals are no longer available.
(my_readsig): Make Static again.
(sig_send): Interpret ERROR_BROKEN_PIPE as ESRCH.  Remove special-case EACCESS
errno setting, just setting errno generally, even for "its_me" case.

12 years ago* exceptions.cc (sigpacket::process): Move signal_exit processing into...
Christopher Faylor [Sat, 26 Nov 2011 02:35:49 +0000 (02:35 +0000)]
* exceptions.cc (sigpacket::process): Move signal_exit processing into...
(_cygtls::signal_exit): ...here.  Close my_readsig and comment on why.
* pinfo.cc (pinfo::exit): Move sigproc_terminate earlier.  Set exiting flag in
lock_process.
* sigproc.cc (my_readsig): Make global.
* sync.cc (muto::exiting_thread): Delete.
(muto::acquire): Delete #if 0'ed code.
* sync.h (muto::exiting_thread): Delete.
(set_exiting_thread): Ditto.
(lock_process::lock_process): Don't worry about setting the exiting thread
since it had no meaning.

12 years ago* strace.cc (attach_process): Use NT_SUCCESS to figure out if
Christopher Faylor [Thu, 24 Nov 2011 21:54:41 +0000 (21:54 +0000)]
* strace.cc (attach_process): Use NT_SUCCESS to figure out if
NtSetInformationProcess succeeded.
(handle_output_debug_string): Put back DebugActiveProcess since it seems to
still be needed (on my system at least).  Detect new format
_STRACE_INTERFACE_ACTIVATE_ADDR which informs whether this is a forked process
or not.  Use that to decide if forkdebug should be handled.

12 years agomissed this in previous checkin
Christopher Faylor [Thu, 24 Nov 2011 21:38:17 +0000 (21:38 +0000)]
missed this in previous checkin

12 years ago* cygthread.h (cygthread::name): Default name to "main" if we are early in the
Christopher Faylor [Thu, 24 Nov 2011 21:36:53 +0000 (21:36 +0000)]
* cygthread.h (cygthread::name): Default name to "main" if we are early in the
process of setting up the DLL and no name is known.
* dcrt0.cc (initial_env): Remove CYGWIN_SLEEP stuff.
(get_cygwin_startup_info): Activate strace here as appropriate.
(dll_crt0_0): Move get_cygwin_startup_info as early as possible to avoid
missing strace output.
* fork.cc (frok::child): Move debugging statement to point where ppid will be
set.
* pinfo.cc (pinfo::thisproc): Remove obsolete call to strace.hello.  Tweak
debug output slightly.
* select.cc (select_stuff::wait): Allow APCS to be triggered while waiting
since we use them now.  Report when that happens.
* sigproc.cc (child_info::child_info): Use strace.active() rather than
strace.attached().
* spawn.cc (child_info_spawn::worker): Only write strace child pid when we know
it's a cygwin process.  Accommodate change to write_child argument list.
* strace.cc (strace::hello): Delete.  Move functionality...
(strace::activate): ...to here.
(mypid): Just use raw GetCurrentProcessId () if myself isn't set.
(strace::write_childpid): Don't wait for subproc_ready.  Remove arg which was
required for it.
* include/sys/strace.h (strace::hello): Delete.
(strace::write_childpid): Delete first argument.

12 years ago* child_info.h (CURR_CHILD_INFO_MAGIC): Reset for previous changes.
Christopher Faylor [Thu, 24 Nov 2011 02:17:55 +0000 (02:17 +0000)]
* child_info.h (CURR_CHILD_INFO_MAGIC): Reset for previous changes.
* dcrt0.cc (get_cygwin_startup_info): Signal readiness when stracing since
strace::write_child relies on it.  Use strace.activate to notify strace
process, passing in arg indicating whether we're forked.
* sigproc.cc (wait_sig): Accommodate new strace::activate argument.
* spawn.cc (child_info_spawn::worker): Oops.  Previous suspended test was
actually correct.  Revert and document.
* strace.cc (strace::activate): Send additional flag indicating whether this is
an attempt to activate a forked process.
(strace::hello): Report on windows pid.
* include/sys/strace.h (strace::strace): Make a dummy.
(strace::activate): Modify declaration to accept an argument.
(strace::write_childpid): Set regparm.

12 years ago* pipe.cc (fhandler_pipe::create): Avoid derefencing a NULL pointer.
Christopher Faylor [Wed, 23 Nov 2011 21:58:43 +0000 (21:58 +0000)]
* pipe.cc (fhandler_pipe::create): Avoid derefencing a NULL pointer.
* child_info.h (child_info): Reorganize some elements so that the ones which
are initialized in a constructor are all together.
* sigproc.cc (child_info::child_info): Initialize values via the constructor
rather than as C statements and make sure that flags is set to zero initially.
* spawn.cc (child_info_spawn::worker): Use iscygwin() test for determining when
to send strace info since it is more foolproof than checking the suspend state.

12 years ago* fhandler.h (fhandler_pipe::create): Rename from the misnamed
Christopher Faylor [Wed, 23 Nov 2011 18:56:57 +0000 (18:56 +0000)]
* fhandler.h (fhandler_pipe::create): Rename from the misnamed
"create_selectable".  Change return to DWORD.
(fhandler_pty_common::pipesize): New constant.
* fhandler_fifo.cc (fhandler_fifo::fhandler_fifo): Reflect create_selectable
name change.
* miscfuncs.cc (CreatePipeOverlapped): Ditto.
* pipe.cc (fhandler_pipe::create): Ditto.
(fhandler_pipe::create): Rename from the misnamed "create_selectable".  Return
DWORD.  Only set pipe size to default when it is passed in as zero.
* fhandler_tty.cc (fhandler_pty_master::setup): Ditto.  Use
fhandler_pty_common::pipesize rather than a raw constant.
* tty.cc (tty::not_allocated): Ditto.
* sigproc.cc (sigproc_init): Use create_selectable to create the signal pipe to
get a more appropriate message based pipe.

12 years ago* sigproc.cc (remove_proc): Don't do busy loop when exiting since it doesn't
Christopher Faylor [Mon, 21 Nov 2011 21:09:33 +0000 (21:09 +0000)]
* sigproc.cc (remove_proc): Don't do busy loop when exiting since it doesn't
matter.

12 years ago* sigproc.cc (remove_proc): Don't do busy loop when execing since thread could
Christopher Faylor [Mon, 21 Nov 2011 19:13:30 +0000 (19:13 +0000)]
* sigproc.cc (remove_proc): Don't do busy loop when execing since thread could
have been terminated prior to setting flag.
* signal.cc (sigwaitinfo): Zero event before closing to signal other threads
that it is no longer available.

12 years ago * faq-using.xml (faq.using.weirdchars): Rewrite.
Corinna Vinschen [Mon, 21 Nov 2011 09:16:23 +0000 (09:16 +0000)]
* faq-using.xml (faq.using.weirdchars): Rewrite.

12 years ago * shared.cc (get_shared_parent_dir): Use global shared_parent_dir
Corinna Vinschen [Fri, 18 Nov 2011 17:38:04 +0000 (17:38 +0000)]
* shared.cc (get_shared_parent_dir): Use global shared_parent_dir
instead of local dir variable and create handle not inheritable to
avoid accumulating stray handles in child processes.
(get_session_parent_dir): Ditto with session_parent_dir variable.

12 years ago * faq-using.xml (faq.using.converting-paths): Remove reference to
Corinna Vinschen [Fri, 18 Nov 2011 11:39:31 +0000 (11:39 +0000)]
* faq-using.xml (faq.using.converting-paths): Remove reference to
cygwin.bat.
(faq.using.emacs): Drop "CYGWIN=tty" setting.
* pathnames.sgml (pathnames-posixdevices): Align list of device names
with changes in 1.7.10.
* setup2.sgml (setup-env-ov): Drop text which assumes that Cygwin
processes are started in console window.  Align wording to lessened
relevance of $CYGWIN.  Don't use dropped CYGWIN setting in example.
(setup-locale-how): Put using console and Cygwin.bat file into
perspective.
(setup-locale-problems): Ditto.

12 years ago * shared.cc (shared_info::create): Open global shared data section
Corinna Vinschen [Thu, 17 Nov 2011 22:08:14 +0000 (22:08 +0000)]
* shared.cc (shared_info::create): Open global shared data section
non-inheritable to avoid accumulating stray handles in child processes.

12 years ago* child_info.h (CURR_CHILD_INFO_MAGIC): Reset.
Christopher Faylor [Wed, 16 Nov 2011 04:09:33 +0000 (04:09 +0000)]
* child_info.h (CURR_CHILD_INFO_MAGIC): Reset.
(cygheap_exec_info::nchildren): Move from child_info_spawn.
(cygheap_exec_info::cchildren): Ditto.
(cygheap_exec_info::record_children): Declare new function.
(cygheap_exec_info::reattach_children): Ditto.
(cygheap_exec_info::alloc): Ditto.
(child_info_spawn::nchildren): Move to cygheap_exec_info.
(child_info_spawn::cchildren): Ditto.
* sigproc.cc (cygheap_exec_info::alloc): Define new function.
(child_info_spawn::cleanup): Accommodate move of children info to
cygheap_exec_info.
(cygheap_exec_info::record_children): Define new function.
(cygheap_exec_info::reattach_children): Ditto.
(child_info_spawn::record_children): Use cygheap_exec_info function to
accomplish this task.
(child_info_spawn::reattach_children): Ditto.
* spawn.cc (child_info_spawn::worker): Allocate moreinfo using
cygheap_exec_info::alloc.
* dcrt0.cc (child_info_fork::alloc_stack_hard_way): Use abort for the error to
avoid a retry.

12 years ago* pinfo.cc (_pinfo::dup_proc_pipe): Fatalize a warning when debugging.
Christopher Faylor [Mon, 14 Nov 2011 18:22:46 +0000 (18:22 +0000)]
* pinfo.cc (_pinfo::dup_proc_pipe): Fatalize a warning when debugging.

12 years ago* strace.cc (handle_output_debug_string): Disable code which attempted to add
Christopher Faylor [Mon, 14 Nov 2011 17:31:20 +0000 (17:31 +0000)]
* strace.cc (handle_output_debug_string): Disable code which attempted to add
stuff in between '****' blocks since they no longer are the first thing output
by an straced process.

12 years agoRemove erroneously checked-in debugging statements.
Christopher Faylor [Mon, 14 Nov 2011 01:45:42 +0000 (01:45 +0000)]
Remove erroneously checked-in debugging statements.
* cygheap.cc (cygheap_fixup_in_child): Here.
* debug.cc (delete_handle): Here.
* sigproc.cc (child_info_spawn::cleanup): Here.
* spawn.cc (child_info_spawn::worker): Here.

12 years agoupdate copyrights
Christopher Faylor [Mon, 14 Nov 2011 01:37:02 +0000 (01:37 +0000)]
update copyrights

12 years agoThroughout use "have_execed" macro rather than "hExeced" global handle.
Christopher Faylor [Mon, 14 Nov 2011 01:29:49 +0000 (01:29 +0000)]
Throughout use "have_execed" macro rather than "hExeced" global handle.
Throughout rename _PROC_* to _CH_*.
* child_info.h: Include "pinfo.h".
(child_info_types): Rename _PROC_* -> _CH_* to avoid confusion with similarly
named constants.
(_PROC_*): Delete unneeded aliases.
(PROC_*): Ditto.
(CURR_CHILD_INFO_MAGIC): Ditto.
(cchildren): Define using "pinfo_minimal".
(child_info::set_saw_ctrl_c): Move to
(child_info_spawn::set_saw_ctrl_c): Here.
(child_info_spawn::lock): New field.
(child_info_spawn::hExeced): Ditto.
(child_info_spawn::ev): Ditto.
(child_info_spawn::~child_info_spawn): Move to sigproc.cc.
(child_info_spawn::child_info_spawn): Ditto.
(child_info_spawn::cleanup): Declare new function.
(child_info_spawn::set_saw_ctrl_c): Move to this class.  Set flag only when
execed and return true when we have set the flag.
(child_info_spawn::child_info_spawn::signal_myself_exited): New function.
(child_info_spawn::wait_for_myself): Ditto.
(child_info_spawn::has_execed_cygwin): Ditto.
(child_info_spawn::has_execed): Ditto.  Replaces "hExeced" test.
(child_info_spawn::operator HANDLE&): New operator.
(child_info_spawn::worker): Define old "spawn_guts" as class member.
(ch_spawn): Declare.
(have_execed): Define.
(have_execed_cygwin): Ditto.
* cygheap.h: Update comment.
* dcrt0.cc (get_cygwin_startup_info): Use _CH_* enums.
(child_info_spawn::handle_spawn): Ditto.
(dll_crt0_0): Ditto.
(multiple_cygwin_problem): Ditto.
* exceptions.cc (chExeced): Delete obsolete declaration.
(ctrl_c_handler): Reference set_saw_ctrl_c via new ch_spawn global.
* globals.cc (hExeced): Delete.
* pinfo.cc (pinfo::thisproc): Refer to cygheap as ::cygheap for consistency in
handle naming when -DDEBUGGING.
(pinfo::init): Accommodate case where myself.h is known but h0 is passed in.
(pinfo::pinfo): New constructor for setting up a pinfo passed in by previous
exec'or.
(pinfo::proc_waiter): Don't handle subprocess if we're in the process of
exiting due to an exec of a cygwin process.  Don't close rd_proc_pipe here.
Close it when we actually are finished with the process.  Use new
ch_spawn.signal_myself_exited function to let exec stub know that subprocess
has exited.
(pinfo::wait): Clarify debugging output.
(pinfo::release): Use "close_h" to close all handles to avoid races.
(winpids::add): Assume that elements of the array do not need to be zeroed and
are properly initialized or suffer problems on pinfo::release.  Don't close
hProcess since release does that now.
* pinfo.h: Update comment.
(pinfo_minimal): Move some elements from pinfo here so that child_info_spawn
can use them.
(pinfo): Inherit from pinfo_minimal.
(pinfo::pinfo): Modify to accommodate new pinfo_minimal.
(pinfo::allow_remove): New function.
* sigproc.cc (proc_subproc): Use boolean values for true/false.  Implement
PROC_EXEC_CLEANUP.
(proc_terminate): Set ppid = 1 since the procs list will only be iterated when
the process has not execed.  Don't do any cleanup here since it is now handled
in pinfo::release.
(sigproc_init): Initialize sync_proc_subproc earlier.
(child_info::child_info): Assume that all important fields are properly
initialized and avoid memset().
(child_info_spawn::child_info_spawn): Specifically test for execing and then
set up appropriate fields in the struct.
(child_info_spawn::cleanup): Define new function.
(child_info_spawn::record_children): Specifically test for being execed here.
Fill in pinfo_minimal part of children array.
(child_info_spawn::reattach_children): Use constructor to duplicate information
for previous exec'or.  Add more debugging output.
(remove_proc): Force deletion of thread when exiting due to exec.  Rely on
pinfo::cleanup in release.
* sigproc.h (PROC_EXEC_CLEANUP): New enum.
(PROC_DETACHED_CHILD): Delete.
* spawn.cc (chExeced): Delete.
(child_info_spawn::worker): Rename from spawn_guts.  Use elements of
child_info_spawn throughout rather than ch.whatever.  Use ::cygheap to refer to
global rather than element of child_info.  Use wait_for_myself() rather than
waitpid().  Call child_info_spawn::cleanup on function return.
(spawnve): Reflect movement of spawn_guts functionality into
child_info_spawn::worker.
* syscalls.cc (popen): Ditto.
* winsup.h (spawn_guts): Delete declaration.

12 years ago2011-11-09 Roland McGrath <mcgrathr@google.com>
DJ Delorie [Wed, 9 Nov 2011 18:57:30 +0000 (18:57 +0000)]
2011-11-09  Roland McGrath  <mcgrathr@google.com>
* configure.ac: Add tool checks for READELF and READELF_FOR_TARGET.
* configure: Rebuild.
* Makefile.def (flags_to_pass): Add READELF_FOR_TARGET.
* Makefile.tpl (READELF, READELF_FOR_TARGET): New variables.
(HOST_EXPORTS): Add READELF, READELF_FOR_TARGET.
(BASE_FLAGS_TO_PASS): Add READELF_FOR_TARGET.
(BASE_TARGET_EXPORTS, EXTRA_HOST_FLAGS, EXTRA_TARGET_FLAGS):
Add READELF.
* Makefile.in: Rebuild.

12 years agoMerge libitm changes to configure.ac from gcc master.
Richard Henderson [Tue, 8 Nov 2011 18:23:33 +0000 (18:23 +0000)]
Merge libitm changes to configure.ac from gcc master.

12 years agomerge from gcc
DJ Delorie [Tue, 8 Nov 2011 16:01:51 +0000 (16:01 +0000)]
merge from gcc

12 years ago * libnosys/Makefile.in (install): Use INSTALL_DATA.
Corinna Vinschen [Tue, 8 Nov 2011 15:56:49 +0000 (15:56 +0000)]
* libnosys/Makefile.in (install): Use INSTALL_DATA.

12 years ago * libc/iconv/ccs/Makefile.am: Add missing backslash.
Corinna Vinschen [Tue, 8 Nov 2011 15:46:42 +0000 (15:46 +0000)]
* libc/iconv/ccs/Makefile.am: Add missing backslash.
* libc/iconv/ccs/Makefile.in: Regenerate.

12 years ago * new-features.sgml (ov-new1.7.10): Document ptsname_r.
Corinna Vinschen [Tue, 8 Nov 2011 09:25:25 +0000 (09:25 +0000)]
* new-features.sgml (ov-new1.7.10): Document ptsname_r.

12 years ago * posix.sgml (std-gnu): Add ptsname_r.
Corinna Vinschen [Tue, 8 Nov 2011 09:24:58 +0000 (09:24 +0000)]
* posix.sgml (std-gnu): Add ptsname_r.

12 years ago* fhandler.h (__ptsname): New macro.
Christopher Faylor [Tue, 8 Nov 2011 06:26:15 +0000 (06:26 +0000)]
* fhandler.h (__ptsname): New macro.
* dtable.cc (decode_tty): Use __ptsname to generate the slave pty name.
* fhandler_tty.cc (fhandler_pty_master::ptsname_r): Ditto.
* bsdlib.cc: Add needed includes for openpty() changes.
(openpty): Use __ptsname to generate the slave pty name.  Close slave fd when
aslave == NULL.

12 years ago* include/cygwin/stdlib.h: Update copyright.
Christopher Faylor [Tue, 8 Nov 2011 05:50:18 +0000 (05:50 +0000)]
* include/cygwin/stdlib.h: Update copyright.

12 years ago* cygwin.din (ptsname_r): Export.
Christopher Faylor [Mon, 7 Nov 2011 20:05:49 +0000 (20:05 +0000)]
* cygwin.din (ptsname_r): Export.
* fhandler.cc (fhandler_base::ptsname_r): Define.
* fhandler.h (fhandler_base::ptsname): Delete.
(fhandler_base::ptsname_r): Declare.
(fhandler_pty_master::ptsname_r): Declare.
* fhandler_tty.cc (fhandler_pty_master::ptsname): Delete.
(fhandler_pty_master::ptsname_r): New reentrant function derived from previous
ptsname.
* syscalls.cc (ptsname_r): Implement new function with functionality similar to
Linux.
(ptsname): Use ptsname_r () to fill out buf.
* include/cygwin/stdlib.h (ptsname_r): Declare.
* include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR to 255 to reflect
export of ptsname_r.
* pinfo.cc (pinfo::wait): Return bool rather than int.
* pinfo.h (info::wait): Ditto.
(pinfo::reattach): Define !defined(_SIGPROC_H) case for consistency.
* sigproc.cc (child_info_spawn::reattach_children): Use correct dwProcessId
rather than pid when duplicating handle.

12 years ago * fhandler.cc (CHUNK_SIZE): Drop NO_COPY.
Corinna Vinschen [Mon, 7 Nov 2011 10:06:45 +0000 (10:06 +0000)]
* fhandler.cc (CHUNK_SIZE): Drop NO_COPY.

12 years ago * syscalls.cc (check_dir_not_empty): Check surplus directory entries
Corinna Vinschen [Mon, 7 Nov 2011 10:03:30 +0000 (10:03 +0000)]
* syscalls.cc (check_dir_not_empty): Check surplus directory entries
by calling NtQueryAttributesFile.  Make STATUS_DIRECTORY_NOT_EMPTY
return value dependent on its status code.  Add long comment to explain.
(unlink_nt): Add comment to explain flaw in checking the sharing mode.
Set status to STATUS_SUCCESS instead of 0.  Add a retry loop to setting
the delete disposition and trying to move a directory to bin to
workaround rare cases of lingering, already deleted subdirectory
entries.  Add long comment to explain.
(rename): Set status to STATUS_SUCCESS instead of 0.

13 years ago* pinfo.cc (status_exit): Recognize STATUS_ILLEGAL_INSTRUCTION.
Christopher Faylor [Sat, 5 Nov 2011 18:47:39 +0000 (18:47 +0000)]
* pinfo.cc (status_exit): Recognize STATUS_ILLEGAL_INSTRUCTION.
(child_info::proc_retry): Ditto.

13 years ago * faq-using.xml (faq.using.fixing-fork-failures): Add new FAQ.
Jon TURNEY [Sat, 5 Nov 2011 18:42:55 +0000 (18:42 +0000)]
* faq-using.xml (faq.using.fixing-fork-failures): Add new FAQ.
* overview2.sgml (ov-hi-process-problems): Describe some difficulties
in implementing fork()

13 years ago* pinfo.cc (status_exit): Return complete error code. Handle
Christopher Faylor [Sat, 5 Nov 2011 18:29:51 +0000 (18:29 +0000)]
* pinfo.cc (status_exit): Return complete error code.  Handle
STATUS_ACCESS_VIOLATION correctly.
(pinfo::set_exit_code): Set self->exitcode directly from status_exit.

13 years ago* pinfo.h (pinfo::reattach): Only set destroy to false when proc_subproc
Christopher Faylor [Fri, 4 Nov 2011 17:07:21 +0000 (17:07 +0000)]
* pinfo.h (pinfo::reattach): Only set destroy to false when proc_subproc
succeeds.  Return true for success.
* sigproc.cc (child_info_spawn::reattach_children): Try harder to clean up on
error by detecting reattach failures too.

13 years ago* sigproc.cc (child_info_spawn::reattach_children): Clean up handle when can't
Christopher Faylor [Fri, 4 Nov 2011 16:52:43 +0000 (16:52 +0000)]
* sigproc.cc (child_info_spawn::reattach_children): Clean up handle when can't
open parent process or suffer handle leak.

13 years ago* sigproc.cc (child_info::sync): Report on exit code in strace output.
Christopher Faylor [Thu, 3 Nov 2011 21:44:05 +0000 (21:44 +0000)]
* sigproc.cc (child_info::sync): Report on exit code in strace output.
(child_info::proc_retry): Don't consider STATUS_ACCESS_VIOLATION as a
restartable event.

13 years ago* sigproc.cc (child_info_spawn::reattach_children): Avoid issuing an error when
Christopher Faylor [Thu, 3 Nov 2011 18:48:27 +0000 (18:48 +0000)]
* sigproc.cc (child_info_spawn::reattach_children): Avoid issuing an error when
we can't duplicate from "parent" since it is probably ok if children of the
previous owner of the pid disappear.

13 years ago * fhandler.cc (off_current): Define local in fhandler_base::raw_write.
Corinna Vinschen [Thu, 3 Nov 2011 17:47:33 +0000 (17:47 +0000)]
* fhandler.cc (off_current): Define local in fhandler_base::raw_write.
Drop erroneous NO_COPY, add _RDATA to make R/O.
(off_append): Ditto.
* globals.cc (_RDATA): Move definition from here...
* winsup.h: ...to here.

13 years ago toplevel:
Rainer Orth [Wed, 2 Nov 2011 15:23:38 +0000 (15:23 +0000)]
toplevel:
* Makefile.tpl (EXTRA_GCC_FLAGS): Remove LIBGCC2_CFLAGS,
LIBGCC2_DEBUG_CFLAGS, LIBGCC2_INCLUDES.
* Makefile.in: Regenerate.

config:
* mh-interix (LIBGCC2_DEBUG_CFLAGS): Remove.

13 years ago[.]
DJ Delorie [Wed, 2 Nov 2011 03:09:07 +0000 (03:09 +0000)]
[.]
* configure.ac (rl78-*-*) New case.
* configure: Regenerate.

[bfd]
* Makefile.am (ALL_MACHINES): Add cpu-rl78.lo.
(ALL_MACHINES_CFILES): Add cpu-rl78.c.
(BFD32_BACKENDS): Add elf32-rl78.lo.
(BFD32_BACKENDS_CFILES): Add elf32-rl78.c.
(Makefile.in): Regenerate.
* archures.c (bfd_architecture): Define bfd_arch_rl78.
(bfd_archures_list): Add bfd_rl78_arch.
* config.bfd: Add rl78-*-elf.
* configure.in: Add bfd_elf32_rl78_vec.
* reloc.c (bfd_reloc_code_type): Add BFD_RELOC_RL78_* relocations.
* targets.c (bfd_target_vector): Add bfd_elf32_rl78_vec.
* Makefile.in: Regenerate.
* bfd-in2.h: Regenerate.
* configure: Regenerate.
* libbfd.h: Regenerate.
* cpu-rl78.c: New file.
* elf32-rl78.c: New file.

[binutils]
* readelf.c: Include elf/rl78.h
(guess_is_rela): Handle EM_RL78.
(dump_relocations): Likewise.
(get_machine_name): Likewise.
(is_32bit_abs_reloc): Likewise.
* NEWS: Mention addition of RL78 support.
* MAINTAINERS: Add myself as RL78 port maintainer.

[gas]
* Makefile.am (TARGET_CPU_CFILES): Add tc-rl78.c.
(TARGET_CPU_HFILES): Add rc-rl78.h.
(EXTRA_DIST): Add rl78-parse.c and rl78-parse.y.
(rl78-parse.c, rl78-parse.h, rl78-parse.o, rl78-defs.h): New rules.
* Makefile.in: Regenerate.
* configure.in: Add rl78 case.
* configure: Regenerate.
* configure.tgt: Add rl78 case.
* config/rl78-defs.h: New file.
* config/rl78-parse.y: New file.
* config/tc-rl78.c: New file.
* config/tc-rl78.h: New file.
* NEWS: Add Renesas RL78.

* doc/Makefile.am (c-rl78.texi): New.
* doc/Makefile.in: Likewise.
* doc/all.texi: Enable it.
* doc/as.texi: Add it.

[include]
* dis-asm.h (print_insn_rl78): Declare.

[include/elf]
* common.h (EM_RL78, EM_78K0R): New.
* rl78.h: New.

[include/opcode]
* rl78.h: New file.

[ld]
* Makefile.am (ALL_EMULATION_SOURCES): Add eelf32rl78.c.
(+eelf32rl78.c): New rule.
* Makefile.in: Regenerate.
* configure.tgt: Add rl78-*-* case.
* emulparams/elf32rl78.sh: New file.
* NEWS: Mention addition of Renesas RL78 support.

[opcodes]
* Makefile.am (TARGET_LIBOPCODES_CFILES): Add rl78-decode.c and
rl78-dis.c.
(MAINTAINERCLEANFILES): Add rl78-decode.c.
(rl78-decode.c): New rule, built from rl78-decode.opc and opc2c.
* Makefile.in: Regenerate.
* configure.in: Add bfd_rl78_arch case.
* configure: Regenerate.
* disassemble.c: Define ARCH_rl78.
(disassembler): Add ARCH_rl78 case.
* rl78-decode.c: New file.
* rl78-decode.opc: New file.
* rl78-dis.c: New file.

13 years ago* config.sub: Update to version 2011-10-29 (added rl78)
DJ Delorie [Wed, 2 Nov 2011 00:56:53 +0000 (00:56 +0000)]
* config.sub: Update to version 2011-10-29 (added rl78)

13 years agoRemove erroneous entry.
Christopher Faylor [Sun, 30 Oct 2011 05:21:07 +0000 (05:21 +0000)]
Remove erroneous entry.

13 years ago* fhandler.h (fhandler_pipe::create_selectable): Remove optional argument, take
Christopher Faylor [Sun, 30 Oct 2011 04:50:36 +0000 (04:50 +0000)]
* fhandler.h (fhandler_pipe::create_selectable): Remove optional argument, take
an options argument for CreateNamedPipe/CreateFile.  Change handle arguments to
expect pointers.
(fhandler_fifo::fifo_state): Delete.
(fhandler_fifo::dummy_client): Ditto.
(fhandler_fifo::open_nonserver): Ditto.
(fhandler_fifo::wait_state): Ditto.
(fhandler_fifo::raw_write): Ditto.
(fhandler_fifo::read_ready): New field.
(fhandler_fifo::write_ready): Ditto.
(fhandler_fifo::wait): Modify argument.
(fhandler_fifo::fifo_name): Add a new argument.
(fhandler_fifo::fixup_after_fork): New function.
* fhandler_fifo.cc (fhandler_fifo::fhandler_fifo): Remove initialization of
expunged elements.  Initialize new handles to NULL.
(fhandler_fifo::open_nonserver): Delete.
(fnevent): New macro for creating a named event.
(fnpipe): New macro for creating a unique named pipe name.
(create_pipe): New macro for simplification of named pipe creation.
(fhandler_fifo::fifo_name): Use new argument when creating a shared name.
(fhandler_fifo::open): Rewrite.  Use events to synchronize.
(pure_debug_printf): New macro, active only when DEBUGGING.
(fhandler_fifo::wait): Rewrite to wait for new fifo events which are supplied
as a parameter.
(fhandler_fifo::raw_read): Rewrite to use handle mechanism to detect
client-side disconnect.
(fhandler_fifo::raw_write): Delete.
(fhandler_fifo::close): Remove accommodations for expunged fields.  Close event
handles.
(fhandler_fifo::dup): Remove accommodations for expunged fields.  Duplicate
event handles.
(fhandler_fifo::fixup_after_fork): New function.  Perform fixups on event
handles.
(fhandler_fifo::set_close_on_exec): Remove accommodations for expunged fields.
Set inheritance for new handle fields.
* miscfuncs.cc (CreatePipeOverlapped): Accommodate changes in
fhandler_pipe::create_selectable.
* tty.cc (tty::not_allocated): Ditto.
* pipe.cc (fhandler_pipe::create): Ditto.
(fhandler_pipe::create_selectable): Accept an extra open_mode argument.  Pass
arguments by reference and allow opening one end of the pipe at a time.
* sys/strace.h (debug_only_printf): Define new macro which calls debug_printf
only when DEBUGGING is defined.

13 years ago* exceptions.cc (sigpacket::process): Avoid a potential deadlock when exiting
Christopher Faylor [Fri, 28 Oct 2011 17:32:38 +0000 (17:32 +0000)]
* exceptions.cc (sigpacket::process): Avoid a potential deadlock when exiting
due to a signal.

13 years ago * new-features.sgml (ov-new1.7.10): Document getgrouplist.
Corinna Vinschen [Fri, 28 Oct 2011 09:27:18 +0000 (09:27 +0000)]
* new-features.sgml (ov-new1.7.10): Document getgrouplist.

13 years ago * cygwin.din (getgrouplist): Export.
Corinna Vinschen [Fri, 28 Oct 2011 09:26:42 +0000 (09:26 +0000)]
* cygwin.din (getgrouplist): Export.
* grp.cc (get_groups): New static function to run the core functionality
of initgroups and getgrouplist.
(initgroups32): Call get_groups and just create supplementary group
list in cygheap.  Rename name of first argument to "user".  Add an
assertion to test for a NULL user name.
(initgroups): Rename name of first argument to "user".
(getgrouplist): New function.
* posix.sgml (std-bsd): Add getgrouplist.
* include/cygwin/grp.h (getgrouplist): Declare.
* include/cygwin/version.h: Bump API minor number.

13 years agobfd:
Joern Rennecke [Thu, 27 Oct 2011 14:27:16 +0000 (14:27 +0000)]
bfd:
        * cpu-epiphany.c: Reinstate full list of Copyright years.
        * elf32-epiphany.c: Likewise.
cpu:
        * epiphany.cpu, epiphany.opc: Likewise.
gas:
        * config/tc-epiphany.c, config/tc-epiphany.h: Likewise.
        * doc/c-epiphany.texi: Likewise.
include:
        * elf/epiphany.h: Likewise.

13 years ago * config.sub: Import these changes from the config project:
Nick Clifton [Thu, 27 Oct 2011 09:45:25 +0000 (09:45 +0000)]
* config.sub: Import these changes from the config project:

2011-10-08  Joern Rennecke <joern.rennecke@embecosm.com>
    Ben Elliston  <bje@gnu.org>

* config.sub (epiphany): New.

2011-09-09  Linas Vepstas  <linasvepstas@gmail.com>
    Ben Elliston  <bje@gnu.org>

        * config.sub (hexagon, hexagon-*): New.

2011-08-23  Roland McGrath  <mcgrathr@google.com>

* config.sub: Rename 32eb to be32, 32el to le32, 64el to le64, and
64eb to be64.

2011-08-16  Roland McGrath  <mcgrathr@google.com>

* config.sub (32eb, 32el, 64eb, 64el): New (pseudo-)CPUs.
(nacl): Grok as alias for 32el-unknown-nacl.

13 years ago* child_info.h (cchildren): New struct.
Christopher Faylor [Wed, 26 Oct 2011 19:42:39 +0000 (19:42 +0000)]
* child_info.h (cchildren): New struct.
(child_info_spawn::nchildren): Rename from nprocs.
(child_info_spawn::children): Change type to cchildren for more bookkeeping
possibilities.
(child_info_spawn::child_info_spawn): Clear nchildren.
(child_info_spawn::record_children): Declare new function.
(child_info_spawn::reattach_children): Ditto.
* dcrt0.cc (child_info_spawn::handle_spawn): Call reattach_children to gather
list of processes we are potentially waiting for.
* pinfo.h (pinfo::pinfo): Make sure that rd_proc_pipe is always cleared.
(pinfo::reattach): New function.
* sigproc.cc: Move pinfo.h earlier so that it can be used in sigproc.h.
(get_proc_lock): Don't bother with a lock during DLL initialization.
(proc_subproc): Handle PROC_REATTACH_CHILD.
(proc_terminate): Orphan children only when we are not an execed process or
when the pid is about to be occupied by a non-cygwin process.
(child_info_spawn::record_children): Define new function.
(child_info_spawn::reattach_children): Ditto.
* sigproc.h (procstuff): Define PROC_REATTACH_CHILD and renumber other
elements.
* spawn.cc (spawn_guts): Record any to-be-waited-for subprocesses if about to
exec a cygwin process.
* sigproc.cc (sig_send): Fix harmless transposition of fifth and six arguments
to DuplicateHandle().
(child_info::child_info): Ditto.
* globals.cc (hExeced): Make NO_COPY.

13 years ago * hookapi.cc (hook_or_detect_cygwin): Take additional handle
Corinna Vinschen [Tue, 25 Oct 2011 16:35:58 +0000 (16:35 +0000)]
* hookapi.cc (hook_or_detect_cygwin): Take additional handle
to a file mapping as parameter.  If this handle is not NULL,
create another file mapping for the IAT.
* spawn.cc (av::fixup): Only map the first 64K of an image and
keep the mapping handle to use as argument to hook_or_detect_cygwin.
* winsup.h (hook_or_detect_cygwin): Add mapping handle as default
parameter in declaration.

13 years agobfd:
Nick Clifton [Tue, 25 Oct 2011 11:18:10 +0000 (11:18 +0000)]
bfd:
* Makefile.am (ALL_MACHINES): Add cpu-epiphany.lo .
(ALL_MACHINES_CFILES): Add cpu-epiphany.c .
(BFD32_BACKENDS): Add elf32-epiphany.lo .
(BFD32_BACKENDS_CFILES): Add elf32-epiphany.c .
* Makefile.in, bfd-in2.h, configure, libbfd.h: Regenerate.
* archures.c (bfd_arch_epiphany): Add.
(bfd_mach_epiphany16, bfd_mach_epiphany32): Define.
(bfd_epiphany_arch): Declare.
(bfd_archures_list): Add &bfd_epiphany_arch.
* config.bfd (epiphany-*-elf): New target case.
* configure.in (bfd_elf32_epiphany_vec): New target vector case.
* reloc.c (BFD_RELOC_EPIPHANY_SIMM8): New relocation.
(BFD_RELOC_EPIPHANY_SIMM24, BFD_RELOC_EPIPHANY_HIGH): Likewise.
(BFD_RELOC_EPIPHANY_LOW, BFD_RELOC_EPIPHANY_SIMM11): Likewise.
(BFD_RELOC_EPIPHANY_IMM11, BFD_RELOC_EPIPHANY_IMM8): Likewise.
* targets.c (bfd_elf32_epiphany_vec): Declare.
(_bfd_target_vector): Add bfd_elf32_epiphany_vec.
* po/SRC-POTFILES.in, po/bfd.pot: Regenerate.
* cpu-epiphany.c, elf32-epiphany.c: New files.
binutils:
* readelf.c (include "elf/epiphany.h")
(guess_is_rela, dump_relocation): Handle EM_ADAPTEVA_EPIPHANY.
(get_machine_name, is_32bit_abs_reloc, is_32bit_pcrel_reloc): Likewise.
(is_16bit_abs_reloc, is_none_reloc): Likewise.
* po/binutils.pot: Regenerate.
cpu:
* cpu/epiphany.cpu, cpu/epiphany.opc: New files.
gas:
* NEWS: Mention addition of Adapteva Epiphany support.
* config/tc-epiphany.c, config/tc-epiphany.h: New files.
* Makefile.am (TARGET_CPU_CFILES): Add config/tc-epiphany.c .
(TARGET_CPU_HFILES): Add config/tc-epiphany.h .
* Makefile.in, configure, doc/Makefile.in, po/POTFILES.in: Regenerate.
* configure.in: Also set using_cgen for epiphany.
* configure.tgt: Handle epiphany.
* doc/Makefile.am (CPU_DOCS): Add c-epiphany.texi .
* doc/all.texi: Set EPIPHANY.
* doc/as.texinfo: Add EPIPHANY-specific text.
* doc/c-epiphany.texi: New file.
* po/gas.pot: Regenerate.
gas/testsuite:
* gas/epiphany: New directory.
include:
* dis-asm.h (print_insn_epiphany): Declare.
* elf/epiphany.h: New file.
* elf/common.h (EM_ADAPTEVA_EPIPHANY): Define.
ld:
* NEWS: Mention addition of Adapteva Epiphany support.
* Makefile.am (ALL_EMULATION_SOURCES): Add eelf32epiphany.c .
(eelf32epiphany.c): New rule.
* Makefile.in: Regenerate.
* configure.tgt: Handle epiphany-*-elf.
* po/ld.pot: Regenerate.
* testsuite/ld-srec/srec.exp: xfail epiphany.
* emulparams/elf32epiphany.sh: New file.
opcodes:
* Makefile.am (HFILES): Add epiphany-desc.h and epiphany-opc.h .
(TARGET_LIBOPCODES_CFILES): Add  epiphany-asm.c, epiphany-desc.c,
epiphany-dis.c, epiphany-ibld.c and epiphany-opc.c .
(CLEANFILES): Add stamp-epiphany.
(EPIPHANY_DEPS): Set.  Make CGEN-generated Epiphany files depend on it.
(stamp-epiphany): New rule.
* Makefile.in, configure, po/POTFILES.in, po/opcodes.pot: Regenerate.
* configure.in: Handle bfd_epiphany_arch.
* disassemble.c (ARCH_epiphany): Define.
(disassembler): Handle bfd_arch_epiphany.
* epiphany-asm.c, epiphany-desc.c, epiphany-desc.h: New files.
* epiphany-dis.c, epiphany-ibld.c, epiphany-opc.c: Likewise.
* epiphany-opc.h: Likewise.

13 years ago * mips.h: Fix a typo in description.
Maciej W. Rozycki [Mon, 24 Oct 2011 14:21:41 +0000 (14:21 +0000)]
* mips.h: Fix a typo in description.

13 years ago * syscalls.cc (unlink_nt): Fix a bug which overwrites the NT status
Corinna Vinschen [Mon, 24 Oct 2011 14:02:32 +0000 (14:02 +0000)]
* syscalls.cc (unlink_nt): Fix a bug which overwrites the NT status
value in case setting the delete disposition returns with
STATUS_DIRECTORY_NOT_EMPTY.

13 years ago * shared.cc (open_shared): Fix memory reservation of essential shared
Corinna Vinschen [Mon, 24 Oct 2011 09:19:58 +0000 (09:19 +0000)]
* shared.cc (open_shared): Fix memory reservation of essential shared
memory regions.  Drop delta computations since delta is always 0 in
non-relocated case.  Add a comment.

13 years ago* fhandler_tty.cc (fhandler_pty_slave::read): Use consistent way for testing
Christopher Faylor [Sun, 23 Oct 2011 19:01:47 +0000 (19:01 +0000)]
* fhandler_tty.cc (fhandler_pty_slave::read): Use consistent way for testing
ReadFile return.
* pipe.cc (fhandler_pipe::create_selectable): Open the write side of the pipe
in message-mode to force writing as "chunks".  Explain why.

13 years ago* path.cc (path_conv::get_nt_native_path): Avoid dereferencing path when it is
Christopher Faylor [Sun, 23 Oct 2011 17:19:17 +0000 (17:19 +0000)]
* path.cc (path_conv::get_nt_native_path): Avoid dereferencing path when it is
NULL.

13 years ago* dtable.cc (dtable::delete_archetype): Improve debugging output.
Christopher Faylor [Sat, 22 Oct 2011 16:26:30 +0000 (16:26 +0000)]
* dtable.cc (dtable::delete_archetype): Improve debugging output.
(dtable::init_std_file_from_handle): Close console handle early, before
initialization.  Build up openflags for passing to open_setup, just to be safe.
(last_tty_dev): New variable.
(fh_last_tty_dev): New macro.
(fh_alloc): Try again to keep track of previously opened tty, this time by just
saving the device and using that to potentially open an archetype.  Avoid
setting the "/dev/tty" name if the creation of the fhandler failed.
(build_fh_pc): Remove unused second argument.  Reorganize how and where the
name is set.  Set last_tty_dev as appropriate.  Avoid a NULL dereference in a
debug printf.
* dtable.h (build_fh_pc): Reflect removal of second parameter.
* fhandler.cc (fhandler_base::reset): Use new '<<' operator to copy pc since it
preserves any potentially previously set name.
(fhandler_base::set_name): Ditto.
* fhandler.h (fhandler_*::clone): Throughout use ccalloc to allocate new
fhandler, primarily to make sure that pc field is properly zeroed.
(fhandler_termios::last): Eliminate.
(fhandler_termios): Remove setting of last.
(fhandler_base::~fhandler_termios): Ditto.
* fhandler_console.cc (fhandler_console::open): Don't make decisions about
opening close-on-exec handles here since it makes no sense for archetypes.
(fhandler_console::init): Assume that input handle has already been opened.
* fhandler_termios.cc (fhandler_termios::last): Delete.
* path.h (path_conv::eq_worker): New function.  Move bulk of operator = here.
(operator <<): New function.
(operator =): Use eq_worker to perform old functionality.

13 years ago* obstack.h [!GNUC] (obstack_free): Avoid cast to int.
DJ Delorie [Sat, 22 Oct 2011 01:35:29 +0000 (01:35 +0000)]
* obstack.h [!GNUC] (obstack_free): Avoid cast to int.
* ansidecl.h (ENUM_BITFIELD): Always use enum in C++

13 years ago * fhandler_disk_file.cc (fhandler_disk_file::rmdir): Check invalid
Corinna Vinschen [Fri, 21 Oct 2011 17:43:00 +0000 (17:43 +0000)]
* fhandler_disk_file.cc (fhandler_disk_file::rmdir): Check invalid
success only on Samba shares.
* mount.cc (fs_info::update): Drop has_buggy_basic_info flag for
NcFsd.
* syscalls.cc (unlink_nt): Fix typo in comment.

13 years agoCheck in missing ChangeLog entry.
Christopher Faylor [Fri, 21 Oct 2011 12:24:58 +0000 (12:24 +0000)]
Check in missing ChangeLog entry.

13 years ago * globals.cc (ro_u_ncfsd): New R/O unicode string.
Corinna Vinschen [Fri, 21 Oct 2011 08:29:19 +0000 (08:29 +0000)]
* globals.cc (ro_u_ncfsd): New R/O unicode string.
* mount.cc (fs_info::update): Check for "NcFsd" FS.  Set flags and
change comments accordingly.
(fs_names): Add entry for NcFsd FS.
* mount.h (enum fs_info_type): Add ncfsd.
(class fs_info): Add ncfsd flag and accessor methods.
* path.h (class path_conv): Add fs_is_ncfsd method.
* syscalls.cc (unlink_nt): Experimentally try delete-on-close on NcFsd
in STATUS_CANNOT_DELETE case.

13 years ago* fhandler.h (fhandler*::copyto): Free path_conv strings first.
Christopher Faylor [Thu, 20 Oct 2011 21:35:59 +0000 (21:35 +0000)]
* fhandler.h (fhandler*::copyto): Free path_conv strings first.
* path.h (cfree_and_null): Rename and expand from cfree_maybe.
(path_conv &operator =): Call free_strings rather than freeing strings
directly.

13 years agoThroughout change TTY_* to PTY_*, tty_* to pty_*, and ttym_* to ptmx_*.
Christopher Faylor [Thu, 20 Oct 2011 14:02:54 +0000 (14:02 +0000)]
Throughout change TTY_* to PTY_*, tty_* to pty_*, and ttym_* to ptmx_*.
* devices.cc: Regenerate.
* dtable.cc: (fh_alloc): Preserve /dev/tty name when that's what we opened.
(build_fh_pc): Preserve any existing name.
* fhandler.cc (fhandler_base::open_with_arch): Ditto.
* fhandler_tty.cc (fhandler_pty_master::fhandler_pty_master): Force the name to
/dev/ptmx while preserving other pty master device information.
* path.h (cfree_maybe): New macro.
(path_conv::operator =): Free any allocated strings in target.
(path_conv::free_strings): Delete unused function.
* sigproc.cc (proc_terminate): Remove previous accommodation for execed
processes since it didn't have the desired effect.  Change comment to a FIXME.
* spawn.cc (chExeced): Mark NO_COPY.
(exe_suffixes): Ditto.

13 years ago * syscalls.cc (try_to_bin): Improve debug output.
Corinna Vinschen [Thu, 20 Oct 2011 10:59:01 +0000 (10:59 +0000)]
* syscalls.cc (try_to_bin): Improve debug output.
(check_dir_not_empty): Take additional path_conv argument.  Improve
debug output.  Change syscall_printf to debug_printf.
(unlink_nt): Improve debug output.  Change syscall_printf to
debug_printf.
(unlink): Change syscall_printf to debug_printf.

* cygthread.h: Fix copyright dates.

13 years ago PR ld/13254
Alan Modra [Wed, 19 Oct 2011 04:13:27 +0000 (04:13 +0000)]
PR ld/13254
include/
* bfdlink.h (struct bfd_link_info): Add error_textrel.
bfd/
* elflink.c (bfd_elf_final_link): Emit error_textrel error.
ld/
* emultempl/elf32.em (gld${EMULATION_NAME}_handle_option): Add
-z text, -z notext, -z textoff options for all targets having
shared lib support.

13 years ago * libc/machine/arm/Makefile.am (lib_a_SOURCES): Add memchr-stub.c,
Nick Clifton [Tue, 18 Oct 2011 11:35:17 +0000 (11:35 +0000)]
* libc/machine/arm/Makefile.am (lib_a_SOURCES): Add memchr-stub.c,
memchr.S.
* libc/machine/arm/arm_asm.h: Add ifdef to allow it to be included
in .S files.
* libc/machine/arm/memchr-stub.c: New file - just selects what to
compile.
* libc/machine/arm/memchr.S: New file - ARMv6t2/v7 version.

* libc/machine/arm/Makefile.am (lib_a_SOURCES): Add strlen-armv7.S.
* libc/machine/arm/strlen-armv7.S: New file.
* libc/machine/arm/strlen.c: Add ifdef optimised code so it isn't
for v7 or 6t2.

* libc/machine/arm/Makefile.in: Regenerate.

13 years ago * path.cc: Extend two comments. Mention the name RtlpCurDirRef
Corinna Vinschen [Tue, 18 Oct 2011 08:47:08 +0000 (08:47 +0000)]
* path.cc: Extend two comments.  Mention the name RtlpCurDirRef
for reference.

13 years ago* dcrt0.cc (dll_crt0_1): Copy argv before passing to main().
Christopher Faylor [Mon, 17 Oct 2011 18:25:04 +0000 (18:25 +0000)]
* dcrt0.cc (dll_crt0_1): Copy argv before passing to main().

13 years ago* sigproc.cc (proc_terminate): Avoid setting ppid to 1 if we're execing.
Christopher Faylor [Mon, 17 Oct 2011 15:35:26 +0000 (15:35 +0000)]
* sigproc.cc (proc_terminate): Avoid setting ppid to 1 if we're execing.

13 years ago* cygerrno.h (__set_errno): Modify debugging output to make searching strace
Christopher Faylor [Sat, 15 Oct 2011 22:37:30 +0000 (22:37 +0000)]
* cygerrno.h (__set_errno): Modify debugging output to make searching strace
logs easier.  Throughout, change /dev/tty* to /dev/pty*.  Throughout, add flags
argument to fhandler_*::dup methods.
* devices.in: Rename (temporarily?) /dev/ttyN to /dev/ptyN.  Add /dev/ptymN
devices for pty masters.
* devices.cc: Regenerate.
* devices.h (MAX_CONSOLES): Set to max number supported by devices.in.
(fh_devices::FH_PTMX): Rename from FH_PTYM.
(device::operator int): Return by reference.
* dtable.cc (fh_alloc): Take pc as an argument rather than just the device.
This makes debugging easier since more information is available.  Actually
implement handling for already-allocated pty master devices.  Make different
decisions when generating fhandler for not-opened devices.  Add kludge to deal
with opening /dev/tty.
(cnew_no_ctor): New macro.
(build_fh_pc): Make debugging output more verbose.  Use new clone() fhandler
interface to duplicate archetypes.  Reset last term opened.
(dtable::dup_worker): Use Use new clone() fhandler interface to duplicate
archetypes.  Pass flags to child dup handler.
(dtable::dup3): Set O_NOCTTY flag if newfd is not stdin/stdout/stderr.
* fhandler.cc (fhandler_base::reset): Rename from operator =() and reduce
functionality and sense of copy direction.
(fhandler_base::open_with_arch): Use published interface to query io_handle().
Use new copyto() fhandler method to copy from/to found archetype.
* fhandler.h: Throughout, delete size(), add copyout, clone, and fhandler_*
(void *) methods.
(fhandler_base::reset): Rename from operator =().
(fhandler_termios::is_dev_tty): Delete.
(fhandler_termios): change "protected" region to "private".
(fhandler_termios::is_dev_tty): Delete.
(fhandler_termios): Rearrange protected/public.
(fhandler_termios::fhandler_termios): Remember last fhandler_termios "opened".
(fhandler_termios::~fhandler_termios): Forget last fhandler_termios opened.
(ioctl): Rename from ioctl_termios.  Take a void * argument.  Reflect argument
change in pinfo::set_ctty.
(fhandler_console::dup): Declare new function.  Set ctty here if appropriate.
(fhandler_pty_master::from_master): Privatize.
(fhandler_pty_master::to_master): Ditto.
(fhandler_pty_master::dwProcessId): Ditto.
(fhandler_pty_master::fhandler_pty_master): Add an `int' argument.
(fhandler_pty_master::open_setup): Declare new function.
(fhandler_pty_master::~fhandler_pty_master): Declare new method.
(fhandler_nodevice): Remove commented out function declaration.
* fhandler_console.cc: Use get_ttyp() instead of tc() throughout.
(fhandler_console::dup): Define new function to set controlling ctty on dup, as
appropriate.
(fhandler_console::ioctl): Reflect ioctl_termios name change.
(fhandler_console::setup): Rename from get_tty_stuff.
(fhandler_console::open_setup): Reflect argument change in pinfo::set_ctty.
(fhandler_console::fhandler_console): Set _tc here.
* fhandler_termios.cc (handler_termios::ioctl): Rename.  Take a void * arg like
other ioctl functions.
* fhandler_tty.cc (fhandler_pty_slave::dup): Call myself->set_ctty to
potentially reset the controlling terminal.
(fhandler_pty_slave::ioctl): Reflect name/arg change for ioctl_termios.
(fhandler_pty_slave::fhandler_pty_slave): Take a "unit" argument.  Call setup()
here so that we will know the unit number of this fhandler as soon as possible.
Set the unit as appropriate.
(handler_pty_master::open): Move most stuff to constructor and open_setup.
(handler_pty_slave::open_setup): Reflect argument change in pinfo::set_ctty.
(handler_pty_master::open_setup): Define new function.
(fhandler_pty_master::cleanup): Clear handles as a flag that the destructor
does not have to do "close" operations.
(fhandler_pty_master::close): Ditto.
(fhandler_pty_master::~fhandler_pty_master): Define new method.
(fhandler_pty_master::ioctl): Reflect name/arg change for ioctl_termios.
(fhandler_pty_master::setup): Allocate tty here.  Rely on handles being
returned from allocated test rather than opening them here.  Avoid setting
_need_nl here since it is already zeroed in the constructor.  Set up device
information with DEV_TTYM_MAJOR.
* path.h (path_conv &operator =): Take a const argument.
(path_conv::dup): Ditto.
(pathconv_arg::PC_OPEN): New enum.
(pathconv_arg::PC_CTTY): Ditto.
(path_types::PATH_CTTY): Ditto.
(path_types::PATH_OPEN): Ditto.
(path_conv::isopen): New method.
(path_conv::isctty_capable): Ditto.
* path.cc (path_conv::check): Set PATH_OPEN and PATH_CTTY as appropriate.
* pipe.cc (fhandler_pipe::open): Use copyto to copy pipe handle.
* syscall.cc (open): Reinstate fd > 2 check to disallow resetting ctty on
non-std* handles.
* tty.cc (tty_list::allocate): Pass out handles for allocated tty.  use
`not_allocated' to find unallocated ttys.  Avoid keeping the lock since the
allocation of the tty should be sufficient to prevent multiple access.
(tty::not_allocated): Clarify comment.  Rename.  Return handles when an unused
tty is found.  Simply test for existing tty.
(tty::exists): Rewrite to use `not_allocated'.
* tty.h (NTTYS): Reset down to actual number supported by devices.in.
(tty::not_allocated): Declare new function.
(tty_list::allocate): Pass out read/write tty handles.  Zero them when not
found.
* fhandler_proc.cc: Reflect name change from FH_PTYM -> FH_PTMX.
* pinfo.h (pinfo::set_ctty): Reduce/reorder arguments passed in.
* pinfo.cc (pinfo::set_ctty): Ditto.  Just use tc() built into the passed-in
fhandler_termios pointer.  Return true if ctty is assigned.
* syscalls.cc (open): Call build_fh_pc with PC_OPEN flag.  Set PC_CTTY if
appropriate.
(stat_worker): Remove is_dev_tty () stuff.

13 years ago * fhandler_process.cc (dos_drive_mappings::fixup_if_match): Convert
Corinna Vinschen [Sat, 15 Oct 2011 19:13:57 +0000 (19:13 +0000)]
* fhandler_process.cc (dos_drive_mappings::fixup_if_match): Convert
native NT network paths into DOS UNC paths.

13 years ago * sec_auth.cc (get_token_group_sidlist): Add CONSOLE LOGON SID on
Corinna Vinschen [Sat, 15 Oct 2011 16:31:57 +0000 (16:31 +0000)]
* sec_auth.cc (get_token_group_sidlist): Add CONSOLE LOGON SID on
systems supporting it.  Never add SERVICE SID but keep code in for
future reference.  Explain why.
(get_priv_list): Add cygpsid pointer parameter.  Point it to the
mandatory integrity SID which matches account and privileges.
(create_token): Fetch mandatory integrity SID from call to
get_priv_list.
(lsaauth): Call get_priv_list with additional NULL pointer.  Change
comment accordingly.
* sec_helper.cc (well_known_console_logon_sid): New static SID.
(cygpriv): Change to structure containing extra flag to store info
about required integrity level.
(privilege_luid): Accommodate changes to cygpriv.  Return integrity
level in new high_integrity parameter.
(privilege_name): Accommodate changes to cygpriv.
(set_privilege): Drop trailing \n from debug output.
(set_cygwin_privileges): Don't set SE_CREATE_GLOBAL_PRIVILEGE anymore
since it's just not needed, but keep code in for future reference.
Change comment accordingly.
* security.h (well_known_console_logon_sid): Declare.
(privilege_luid): Align declaration to above change.
* wincap.h (wincaps::has_console_logon_sid): New element.
* wincap.cc: Implement above element throughout.

13 years ago * cygcheck.cc (dump_sysinfo): Add Windows 8 recognition. Note as
Corinna Vinschen [Thu, 13 Oct 2011 17:50:48 +0000 (17:50 +0000)]
* cygcheck.cc (dump_sysinfo): Add Windows 8 recognition.  Note as
unsupported.  Update products array.

13 years ago * path.cc (find_fast_cwd_pointer): Allow 'push crit-sect-addr' instead
Corinna Vinschen [Thu, 13 Oct 2011 16:47:32 +0000 (16:47 +0000)]
* path.cc (find_fast_cwd_pointer): Allow 'push crit-sect-addr' instead
of 'mov edi, crit-sect-addr; push edi' and set rcall accordingly.

13 years ago * path.cc (copy_cwd_str): Move up in file to be accessible from
Corinna Vinschen [Thu, 13 Oct 2011 15:32:10 +0000 (15:32 +0000)]
* path.cc (copy_cwd_str): Move up in file to be accessible from
class fcwd_access_t.
(class fcwd_access_t): New class to consolidate and hide the details
of the various FAST_CWD implementations.  Add implementation for
Windows 8 Developer Preview.
(fast_cwd_version): Make static private member of fcwd_access_t.
(fast_cwd_ptr): Change base type to fcwd_access_t.
(find_fast_cwd_pointer): Return fcwd_access_t**.
(find_fast_cwd): Ditto.  Rip out all FAST_CWD implementations and use
fcwd_access_t methods instead.
(cwdstuff::override_win32_cwd): Ditto.

13 years ago * fhandler_console.cc (fhandler_console::cursor_set): Disable forcing
Corinna Vinschen [Wed, 12 Oct 2011 14:19:20 +0000 (14:19 +0000)]
* fhandler_console.cc (fhandler_console::cursor_set): Disable forcing
y to the current winBottom position.  Explain why.

13 years ago* cygwin.din: Remove some _tc* exports. Add tcgetsid().
Christopher Faylor [Tue, 11 Oct 2011 23:20:38 +0000 (23:20 +0000)]
* cygwin.din: Remove some _tc* exports.  Add tcgetsid().
* dtable.cc (fh_alloc): Revert ill-advised setting of major/minor.  Use new
is_dev_tty to remember that this device was opened as /dev/tty.
* fhandler.cc (fhandler_base::fstat): Remove leftover debugging statement.
(fhandler_base::tcgetsid): New function.
* fhandler.h ((fhandler_base::tcgetsid): Declare new function.
(fhandler_base::is_dev_tty): Ditto.
(fhandler_termios::opened_as_dev_tty): Declare new field.
(fhandler_termios::is_dev_tty): Declare new function.
(fhandler_termios::tcgetsid): Ditto.
(fhandler_pty_common::use_archetype): Move here from subclass.
(fhandler_pty_slave::use_archetype): Move up.
(fhandler_pty_master::use_archetype): Ditto.
* fhandler_console.cc (fhandler_console::ioctl): Rename second argument from
`buf' to `arg' for consistency.  Call ioctl_termios for common fhandler_termios
ioctl handling.
* fhandler_tty.cc (fhandler_pty_slave::ioctl): Call ioctl_termios for common
fhandler_termios ioctl handling.
(fhandler_pty_master::ioctl): Ditto.
* fhandler_termios.cc (fhandler_termios::tcgetsid): Implement new function.
(fhandler_termios::ioctl_termios): Ditto.  Implements TIOCSCTTY handling.
* syscalls.cc (stat_worker): Set /dev/tty device info when appropriate.
* termios.cc (tcgetpgrp): Avoid extraneous "isatty" check.
(tcgetsid): Implement new function.
* include/cygwin/version.h: Bump CYGWIN_VERSION_API_MINOR to 253.
* include/sys/termios.h (TIOCSCTTY): Define.

13 years ago * utils.sgml (getconf): Expand documentation.
Yaakov Selkowitz [Tue, 11 Oct 2011 21:53:57 +0000 (21:53 +0000)]
* utils.sgml (getconf): Expand documentation.

13 years ago* dtable.cc (fh_alloc): Don't parse /dev/tty if ctty is < 0. Reset major/minor
Christopher Faylor [Tue, 11 Oct 2011 12:39:31 +0000 (12:39 +0000)]
* dtable.cc (fh_alloc): Don't parse /dev/tty if ctty is < 0.  Reset major/minor
from the specific tty to those for /dev/tty.

13 years ago * libc/time/mktm_r.c: (__tzcalc_limits) Fix Julian day calculation.
Corinna Vinschen [Tue, 11 Oct 2011 11:28:05 +0000 (11:28 +0000)]
* libc/time/mktm_r.c: (__tzcalc_limits) Fix Julian day calculation.
* libc/time/mktime.c: (mktime) Fix tm_yday, tm_mday updating when
timezone causes roll over.

13 years agooops - fix typo in previous delta.
Nick Clifton [Tue, 11 Oct 2011 09:29:56 +0000 (09:29 +0000)]
oops - fix typo in previous delta.

13 years agooops - omitted from previous delta.
Nick Clifton [Tue, 11 Oct 2011 07:38:33 +0000 (07:38 +0000)]
oops - omitted from previous delta.

13 years ago* syscalls.cc (open): Add temporary kludge to avoid assigning the controlling
Christopher Faylor [Mon, 10 Oct 2011 22:01:06 +0000 (22:01 +0000)]
* syscalls.cc (open): Add temporary kludge to avoid assigning the controlling
tty on open unless the open is for stdin/stdout/stderr.
* tty.cc (tty_list::connect): Set ENXIO when can't find a tty.

13 years ago * fhandler.h (fhandler_process::closedir): Declare.
Corinna Vinschen [Mon, 10 Oct 2011 18:59:56 +0000 (18:59 +0000)]
* fhandler.h (fhandler_process::closedir): Declare.
* fhandler_process.cc (fhandler_process::closedir): New function to
avoid a SEGV in fhandler_proc::closedir.

13 years ago * cygserver.sgml: Change -v to -V, same as in sources.
Corinna Vinschen [Mon, 10 Oct 2011 15:52:48 +0000 (15:52 +0000)]
* cygserver.sgml: Change -v to -V, same as in sources.

13 years ago * cygserver.cc (print_usage): Align output to utilities in utils
Corinna Vinschen [Mon, 10 Oct 2011 15:48:54 +0000 (15:48 +0000)]
* cygserver.cc (print_usage): Align output to utilities in utils
directory.
(print_version): Ditto.

13 years ago * ldd.cc (VERSION): Remove.
Corinna Vinschen [Mon, 10 Oct 2011 15:34:52 +0000 (15:34 +0000)]
* ldd.cc (VERSION): Remove.

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