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-10-04 06:34:20 +0400
committerChristopher Faylor <me@cgf.cx>2001-10-04 06:34:20 +0400
commit8af0f81d522b3143ad6fcd5504e4b2ccc7c5b856 (patch)
treec0bd0012ea7fe135f321aea6b48fed3601ec6517 /winsup/cygwin/fhandler_console.cc
parent34d2d0397582c6ce0d5a4df984a83766cd752c33 (diff)
* dcrt0.cc (dll_crt0_1): Don't close hexec_proc if it is NULL.
* fork.cc (vfork): Add debugging statements. * path.cc (get_device_number): Make static. Rewrite to inspect both unix and windows paths. (get_raw_device_number): Just check for parts of raw device that we care about. (get_devn): New function, pulled from get_device_number. (win32_device_name): Accomodate arg changes to get_device_number. (mount_info::get_device_number): Call get_device_number on translated Windows path. * spawn.cc (spawn_guts): Don't treat P_VFORK differently from P_NOWAIT. Add handle to child's shared region to child so that it will be preserved if the parent goes away. * fhandler.h: Throughout, simplify to one open method for all fhandler classes, requiring a path_conv first element. * fhandler.cc (fhandler_base::open): Remove obsolete method. Generalize to require path_conv * as first argument. (fhandler_disk_file::open): Remove obsolete method. (fhandler_disk_file::open): Use path_conv pointer rather than reference. * fhandler_clipboard.cc (fhandler_dev_clipboard::dup): Use new open method. (fhandler_dev_clipboard::open): Accomodate new argument for open methods. * fhandler_console.cc (fhandler_console::open): Ditto. (fhandler_console::dup): Use new open method. (fhandler_console::fixup_after_fork): Ditto. (fhandler_console::fixup_after_exec): Ditto. * fhandler_dsp.cc (fhandler_dev_dsp::open): Accomodate new argument for open methods. * fhandler_floppy.cc (fhandler_dev_floppy::open): Ditto. * fhandler_mem.cc (fhandler_dev_mem::open): Ditto. * fhandler_random (fhandler_dev_random::open): Ditto. * fhandler_raw.cc (fhandler_dev_raw::open): Ditto. * fhandler_serial.cc (fhandler_serial::open): Ditto. * fhandler_tape.cc (fhandler_dev_tape::open): Ditto. * fhandler_tty.cc (fhandler_tty_slave::open): Ditto. (fhandler_pty_master::open): Ditto. * fhandler_windows.cc (fhandler_windows::open): Ditto. * fhandler_zero.cc (fhandler_dev_zero::open): Ditto. * fhandler_socket.cc (fhandler_socket::set_connect_secret): Accomodate new argument for open methods. * syscalls.cc (_open): Ditto. (stat_worker): Ditto.
Diffstat (limited to 'winsup/cygwin/fhandler_console.cc')
-rw-r--r--winsup/cygwin/fhandler_console.cc10
1 files changed, 5 insertions, 5 deletions
diff --git a/winsup/cygwin/fhandler_console.cc b/winsup/cygwin/fhandler_console.cc
index 9dd98e7f8..3756ad2ab 100644
--- a/winsup/cygwin/fhandler_console.cc
+++ b/winsup/cygwin/fhandler_console.cc
@@ -542,7 +542,7 @@ fhandler_console::scroll_screen (int x1, int y1, int x2, int y2, int xn, int yn)
}
int
-fhandler_console::open (const char *, int flags, mode_t)
+fhandler_console::open (path_conv *, int flags, mode_t)
{
HANDLE h;
@@ -617,7 +617,7 @@ fhandler_console::dup (fhandler_base *child)
{
fhandler_console *fhc = (fhandler_console *) child;
- if (!fhc->open (get_name (), get_flags () & ~O_NOCTTY, 0))
+ if (!fhc->open (NULL, get_flags () & ~O_NOCTTY, 0))
system_printf ("error opening console, %E");
fhc->default_color = default_color;
@@ -1723,7 +1723,7 @@ fhandler_console::init (HANDLE f, DWORD a, mode_t bin)
mode = O_WRONLY;
if (a == (GENERIC_READ | GENERIC_WRITE))
mode = O_RDWR;
- open (0, mode);
+ open ((path_conv *) NULL, mode);
if (f != INVALID_HANDLE_VALUE)
CloseHandle (f); /* Reopened by open */
@@ -1752,7 +1752,7 @@ fhandler_console::fixup_after_fork (HANDLE)
/* Windows does not allow duplication of console handles between processes
so open the console explicitly. */
- if (!open (get_name (), O_NOCTTY | get_flags (), 0))
+ if (!open (NULL, O_NOCTTY | get_flags (), 0))
system_printf ("error opening console after fork, %E");
if (!get_close_on_exec ())
@@ -1782,7 +1782,7 @@ fhandler_console::fixup_after_exec (HANDLE)
HANDLE h = get_handle ();
HANDLE oh = get_output_handle ();
- if (!open (get_name (), O_NOCTTY | get_flags (), 0))
+ if (!open (NULL, O_NOCTTY | get_flags (), 0))
{
int sawerr = 0;
if (!get_io_handle ())