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>2001-01-28 08:51:15 +0300
committerChristopher Faylor <me@cgf.cx>2001-01-28 08:51:15 +0300
commit2a6fc028badee6ab9a4df2b1b395dbb701d965fb (patch)
tree22d3b565c2f57907367012419b1c63765043d05d /winsup/cygwin/fhandler_console.cc
parent022ce214de829810a9ddd1a747be03ac95185bb1 (diff)
Throughout, change 'cygwin_shared.mount' to 'mount_table'.
* child_info.h (child_info): Move shared_h, console_h to cygheap. Add mount_h. * cygheap.h (init_cygheap): Add shared_h, console_h. * cygheap.cc (init_cheap): Initialize heap at a fixed location after the shared memory regions. Initialize cygheap->user name here. * dcrt0.cc (dll_crt0_1): Call getpagesize () to initialize constants. Remove cygheap_init since it is done in shared_init now. (_dll_crt0): Initialize mount_h, remove shared_h and console_h initialization. * fhandler_console.cc (console_shared_h): Eliminate. (get_tty_stuff): Use cygheap->console_h rather than console_shared_h. * heap.cc (heap_init): Use page size constant calculated earlier in initialization. * shared.cc: Eliminate cygwin_shared_h. Add cygwin_mount_h. (mount_table_init): New function for initializing a user mount table. (open_shared_file_map): Use constant for shared memory region. Initialize cygheap and mount table here. (open_shared): Improve debugging output. (shared_info::initialize): Eliminate call to mount.init. (shared_terminate): Use cygheap->shared_h. Close cygwin_mount_h. (open_shared_file_map): Eliminate. * shared_info.h (mount_info): Add a version field. (shared_align_past): New macro for calculating location for shared memory regions. * sigproc.cc (init_child_info): Eliminate shared_h, console_h. * spawn.cc (spawn_guts): Pass on cygwin_mount_h iff not a different user. * syscalls.cc (system_info): New global holding system memory defaults. (getpagesize): Use system_info. * uinfo.cc (internal_getlogin): Only fill in user name if nonexistent. * winsup.h: Declare system_info. * passwd.cc (read_etc_passwd): Use cygheap->user.name () rather than retrieving the name again.
Diffstat (limited to 'winsup/cygwin/fhandler_console.cc')
-rw-r--r--winsup/cygwin/fhandler_console.cc7
1 files changed, 3 insertions, 4 deletions
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc
index 3af96d74a..54da3b71f 100644
--- a/winsup/cygwin/fhandler_console.cc
+++ b/winsup/cygwin/fhandler_console.cc
@@ -20,6 +20,7 @@ details. */
#include <wincon.h>
#include <ctype.h>
#include <sys/cygwin.h>
+#include "cygheap.h"
#include "cygerrno.h"
#include "fhandler.h"
#include "sync.h"
@@ -49,8 +50,6 @@ const char * get_nonascii_key (INPUT_RECORD&, char *);
static BOOL use_mouse = FALSE;
-HANDLE console_shared_h;
-
static tty_min NO_COPY *shared_console_info = NULL;
/* Allocate and initialize the shared record for the current console.
@@ -61,10 +60,10 @@ get_tty_stuff (int force = 0)
if (shared_console_info && !force)
return shared_console_info;
- shared_console_info = (tty_min *) open_shared (NULL, console_shared_h,
+ shared_console_info = (tty_min *) open_shared (NULL, cygheap->console_h,
sizeof (*shared_console_info),
NULL);
- ProtectHandle (console_shared_h);
+ ProtectHandle (cygheap->console_h);
shared_console_info->setntty (TTY_CONSOLE);
shared_console_info->setsid (myself->sid);
return shared_console_info;