Change use of BOOL, TRUE, FALSE to bool, true, false, as appropriate,

throughout.
* tty.cc (tty::common_init): Remove call to SetKernelObjectSecurity and edit
some comments.
* cygheap.h (init_cygheap::ctty): Add new element.
* devices.in (device::parse): Remove special handling for /dev/tty.
* devices.cc: Regenerate.
* dtable.cc (build_fh_pc): Don't reset /dev/tty device.  Let the device opener
do that.
* fhandler_termios.cc (tty_min::set_ctty): Redefine to _pinfo class.
* fhandler_tty.cc (fhandler_tty_common::set_close_on_exec): Avoid setting
noninherit flag for ctty.
* tty.h: Move BOOLs to bools.
(tty_min::set_ctty): Redeclare to _pinfo class.
* pinfo.cc (_pinfo::set_ctty): Define new function based on tty_min::set_ctty.
Change first argument from tty number to tty_min class.
* pinfo.h (_pinfo::set_ctty): Declare.
* fhandler_console.cc (fhandler_console::get_tty_stuff): Reflect move of
set_ctty to _pinfo class.
* fhandler_tty.cc (fhandler_tty_slave::open): Treat FH_TTY specially.  Use
saved cygheap value if it exists.  Otherwise convert to real device and save on
first time open.
(fhandler_tty_common::dup): Potentially set controlling tty if duping a slave
tty.
* syscalls.cc (setsid): Close controlling tty in cygheap.
* tty.cc: Change some BOOLs to bools.
This commit is contained in:
Christopher Faylor
2003-12-07 22:37:12 +00:00
parent 2e3ff06d3c
commit 2e008fb91f
41 changed files with 425 additions and 384 deletions

View File

@ -273,14 +273,14 @@ fhandler_dev_tape::ioctl (unsigned int cmd, void *buf)
case MTRETEN:
if (! tape_get_feature (TAPE_DRIVE_END_OF_DATA))
ret = ERROR_INVALID_PARAMETER;
else if (! (ret = tape_set_pos (TAPE_REWIND, 0, FALSE)))
else if (! (ret = tape_set_pos (TAPE_REWIND, 0, false)))
ret = tape_prepare (TAPE_TENSION);
break;
case MTBSFM:
ret = tape_set_pos (TAPE_SPACE_FILEMARKS, -op->mt_count, TRUE);
ret = tape_set_pos (TAPE_SPACE_FILEMARKS, -op->mt_count, true);
break;
case MTFSFM:
ret = tape_set_pos (TAPE_SPACE_FILEMARKS, op->mt_count, TRUE);
ret = tape_set_pos (TAPE_SPACE_FILEMARKS, op->mt_count, true);
break;
case MTEOM:
if (tape_get_feature (TAPE_DRIVE_END_OF_DATA))
@ -497,7 +497,7 @@ static int _tape_set_pos (HANDLE hTape, int mode, long count)
}
int
fhandler_dev_tape::tape_set_pos (int mode, long count, BOOLEAN sfm_func)
fhandler_dev_tape::tape_set_pos (int mode, long count, bool sfm_func)
{
unsigned long pos, tgtpos;
@ -603,7 +603,7 @@ fhandler_dev_tape::tape_erase (int mode)
break;
}
return tape_error (EraseTape (get_handle (), mode, FALSE), "tape_erase");
return tape_error (EraseTape (get_handle (), mode, false), "tape_erase");
}
int
@ -617,7 +617,7 @@ fhandler_dev_tape::tape_prepare (int action)
return tape_error (lasterr, "tape_prepare");
}
BOOLEAN
bool
fhandler_dev_tape::tape_get_feature (DWORD parm)
{
DWORD varlen;
@ -631,7 +631,7 @@ fhandler_dev_tape::tape_get_feature (DWORD parm)
;
if (lasterr)
return FALSE;
return false;
return ((parm & TAPE_DRIVE_HIGH_FEATURES)
? ((dp.FeaturesHigh & parm) != 0)