Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2012-02-14 23:08:20 +0400
committerChristopher Faylor <me@cgf.cx>2012-02-14 23:08:20 +0400
commit4eb5175d905a233eea5651489a1f9698159b9c67 (patch)
tree89ed4c8efac9f1e5c12dc73791535702cef2749c /winsup/cygwin/syscalls.cc
parent5401796acfc2b971a2f2c62eb43dab4ba540b0e5 (diff)
* pinfo.cc (_pinfo::set_ctty): Revert 2012-02-07 change to skip function if tty
in question == our ctty. * syscalls.cc (setsid): Avoid two function calls. * dtable.cc (dtable::dup_worker): Remove debugging. * init.cc (search_for): Calculate for every new process rather than using shared value. (threadfunc_ix): Fill in for ever new process rather than sing shared value.
Diffstat (limited to 'winsup/cygwin/syscalls.cc')
-rw-r--r--winsup/cygwin/syscalls.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/winsup/cygwin/syscalls.cc b/winsup/cygwin/syscalls.cc
index 539f3716f..8cdadb2d7 100644
--- a/winsup/cygwin/syscalls.cc
+++ b/winsup/cygwin/syscalls.cc
@@ -1016,8 +1016,8 @@ setsid (void)
else
{
myself->ctty = -2;
- myself->sid = getpid ();
- myself->pgid = getpid ();
+ myself->sid = myself->pid;
+ myself->pgid = myself->pid;
if (cygheap->ctty)
cygheap->close_ctty ();
syscall_printf ("sid %d, pgid %d, %s", myself->sid, myself->pgid, myctty ());