Commit Graph

978 Commits

Author SHA1 Message Date
Corinna Vinschen 1636a5a1e8 * mmap.cc (mmap): Outflank copy-on-write problem on 9x by
setting access mode to FILE_MAP_READ when read access is requested.
2001-03-26 18:17:15 +00:00
Christopher Faylor aa73152ef7 * dlfcn.cc (check_access): Eliminate.
(check_path_access): Use passed in path_conv buf.
(get_full_path_of_dll): Use passed in name buf to avoid a static.  Rip out most
of the path checking since LoadLibrary will do all of this automatically.
(dlopen): Set errno when appropriate (may not be compliant?).
* environ.cc (posify): Don't pass in "native" path if it seems to actually be
posix.
2001-03-26 01:16:11 +00:00
Christopher Faylor db0421f6ec * fhandler.h (fhandler_dev_clipboard): Extend to support writing.
* fhandler_clipboard.cc (fhandler_dev_clipboard::fhandler_dev_clipboard):
Initialize new fields.  Open clipboard here.
(fhandler_dev_clipboard::dup): New method.
(fhandler_dev_clipboard::open): Accomodate new fields.  Register clipboard
here, if appropriate.
(set_clipboard): New function.  Moves buffer to clipboard.
(fhandler_dev_clipboard::write): Truly implement clipboard writing.
(fhandler_dev_clipboard::read): Reimplement to allow successive reads.
(fhandler_dev_clipboard::lseek): Truly implement seeks in clipboard.
(fhandler_dev_clipboard::close): Clear out new fields.  Support sequential
reads and sequential writes.  Support for binary data via a native clipboard
format.
2001-03-22 22:11:34 +00:00
Christopher Faylor 0b30bad456 * fhandler_console.cc (fhandler_console::set_default_attr): Update console
color attributes on tty reset.
2001-03-22 18:19:00 +00:00
Christopher Faylor c445814840 * autoload.cc (kernel32_init): New function for kernel32 autoload
initialization.
(SignalObjectAndWait): Add conditional load of this function when it is
available.
2001-03-22 03:42:08 +00:00
Christopher Faylor 99a40adcd9 add new file. 2001-03-21 16:06:22 +00:00
Christopher Faylor 6b2a2aa4af Add missing files. 2001-03-21 14:00:29 +00:00
Christopher Faylor 9a08b2c02e * sched.cc: New file. Implement sched*.
* include/sched.h: New file.  User land includes for sched*.
* Makefile.in: Add sched.o
* cygwin.din: Add exports for sched*.
2001-03-21 02:17:58 +00:00
Christopher Faylor a1299ba54b * dtable.cc: Guard against new winsock.h/winsock2.h warnings when mixing
winsock*.h and sys/types.h.
* fhandler_socket.cc: Ditto.
* net.cc: Ditto.
* select.cc: Ditto.
* exceptions.cc: Remove unneeded define.
2001-03-20 19:50:28 +00:00
Christopher Faylor dac9c6045f * include/winsock.h (_SYS_TYPES_H macro guard for int types): Remove; use only
_BSDTYPES_DEFINED macro now defined in newlib sys/types.h.
(SYS_TYPES_H macro guard for fd_set): Replace with_SYS_TYPES_FD_SET macro now
defined in newlib sys/types.h.  Emit warning if defined.
* include/winsock2.h: Ditto.
* include/windows.h (Win32_Winsock): Replace with new macros __USE_W32_SOCKETS
and warn of deprecation.
2001-03-20 19:27:37 +00:00
DJ Delorie eec74f4ac6 * configure: fix regeneration bug. 2001-03-20 01:26:45 +00:00
Christopher Faylor b8c8fa1786 * exceptions.cc (interruptible): Update debugging output.
(setup_handler): Ensure that wait_sig loop wakes up when we punt on sending a
signal.
* poll.cc (poll): Add signal guard here.
2001-03-19 22:48:26 +00:00
Egor Duda 78ace8a7e5 * tty.h (tty::create_inuse): Add new parameter to allow non-
inheritable 'inuse' events.
* tty.cc (tty::create_inuse): Use new parameter.
* fhandler_tty.cc (fhandler_tty_master::init): Ditto.
* fhandler_tty.cc (fhandler_pty_master::open): Ditto.
* fhandler_tty.cc (fhandler_tty_master::init): Create master_alive
event.
* tty.cc (tty_list::terminate): Close master_alive event.
* fhandler_tty.cc (fhandler_tty_common::close): Send EOF to slaves
when master side is closed.
2001-03-19 18:27:37 +00:00
Corinna Vinschen 98750a8404 * mmap.cc (map::get_list_by_fd): Avoid calling `get_namehash' when
file descriptor is -1.
2001-03-19 13:33:51 +00:00
Corinna Vinschen 30f326bf5e * syscalls.cc (check_posix_perm): New static function.
(fpathconf): Add _PC_POSIX_PERMISSIONS and _PC_POSIX_SECURITY
        support.
        (pathconf): Ditto.
        * include/cygwin/version.h: Bump API minor number to 37.
2001-03-19 11:02:41 +00:00
Christopher Faylor 94b03f2380 Fix spacing, copyrights. 2001-03-18 21:11:25 +00:00
Christopher Faylor 51cb7ca7ac fix spacing. 2001-03-18 20:58:18 +00:00
Egor Duda 5e8e21d938 * fhandler.h (fhandler_tty_slave): Declare new methods.
* select.cc (fhandler_tty_slave::select_read): New method.
* select.cc (fhandler_tty_slave::ready_for_read): Ditto.
* select.cc (verify_tty_slave): New function.
* fhandler_termios.cc (fhandler_termios::line_edit): Empty input
buffer on signal.
* fhandler_tty.cc (fhandler_tty_slave::read): Check for input data
after reading from pipe. Reset event if input pipe is empty.
* tty.h (class tty): Allow creating events with manual reset.
* tty.cc (tty::get_event): Use manual_reset flag.
* tty.cc (tty::common_init): Create input_available_event with
manual reset.
2001-03-18 18:05:01 +00:00
Christopher Faylor ca1cea7ed3 Update copyrights. 2001-03-18 03:34:05 +00:00
Christopher Faylor 9d1373cf8a Update copyright. 2001-03-18 03:25:30 +00:00
Christopher Faylor 00a7496150 * external.cc (fillout_pinfo): Match windows pid, as well as cygwin pid when
passed in pid.  Don't prematurely break when searching for a pid.
* thread.h (_winsup_t): Eliminate unneeded field.
2001-03-18 02:49:29 +00:00
Christopher Faylor ee57685985 * kill.cc (forcekill): Use dwProcessId when opening a process, not the Cygwin
pid.
2001-03-18 02:47:39 +00:00
Corinna Vinschen 8eb72e632c * net.cc (get_95_ifconf): Use strcasematch instead of strcasecmp.
* syscalls.cc (_unlink): Ditto.
        (_rename): Ditto.
2001-03-17 19:53:52 +00:00
David Starks-Browning 75c12e1f7a British -> US spelling.
Add .inputrc tip to entry "How can I copy and paste into Cygwin console windows?"
2001-03-17 18:50:22 +00:00
Christopher Faylor 57499703f2 * path.cc (suffix_scan::next): Avoid searching for foo.lnk twice when input is
"foo".
2001-03-17 17:44:53 +00:00
Corinna Vinschen 298fad4623 * net.cc (cygwin_socket): Set protocol to 0 when address family is
AF_UNIX to avoid WSAEPROTONOSUPPORT error.
2001-03-17 17:13:52 +00:00
Corinna Vinschen f52488f76b * net.cc (cygwin_socket): Pass protocol parameter to socket call. 2001-03-17 17:04:45 +00:00
David Starks-Browning 3614840015 Remove "not yet updated" caveat from entry:
"How is the DOS/Unix CR/LF thing handled?"
2001-03-17 16:18:01 +00:00
Christopher Faylor b63a3f55a7 * dir.cc (readdir): Use strcasematch for consistency.
* path.cc (symlink_info): Eliminate known_suffix.
(path_conv::check): Always copy ext_here to end of buffer, if found.
(suffix_scan): Eliminate ext_here, add suffixes_start.
(suffix_scan::has): Eliminate an argument.  Reorganize.  Always return pointer
to end of input path.
(suffix_scan::next): Take a second pass through the suffix list looking for
.lnk.
(symlink_info::check): Eliminate known_suffix usage.
2001-03-17 07:09:41 +00:00
Christopher Faylor 92f4bf9725 Fix typo. 2001-03-17 05:14:16 +00:00
Christopher Faylor db15b3e359 Accomodate all devices. 2001-03-17 05:11:20 +00:00
Christopher Faylor 5bb22c6b1d * syscalls.cc (stat_dev): Give devices full read/write. 2001-03-17 05:06:14 +00:00
Christopher Faylor c0c9de3c66 * thread.cc (MTinterface::CreateCond): Check for null attr pointer. 2001-03-17 04:49:13 +00:00
Christopher Faylor ddca580f9a * fhandler_termios.cc (fhandler_termios::line_edit): Don't accept input when a
signal is sent or we'll end up in an EOF/signal race.
2001-03-17 02:15:33 +00:00
Christopher Faylor ed4c976cf2 fix spelling error. 2001-03-17 01:45:40 +00:00
Christopher Faylor b65c6896c8 * path.cc: Translate scan states from defines to enums.
(suffix_scan): Rename state to nextstate for clarity.
(lnk_match): Change to allow multiple states to indicate that a .lnk has been
matched.
(suffix_scan::has): Eliminate a goto.  Handle .lnk as a special case, since a
.lnk may also need to be tacked on the end of a .lnk.
(suffix_scan::next): Don't increment next state.  Set it specifically.
Recognize new .lnk states.
2001-03-17 01:29:14 +00:00
Christopher Faylor 5ccbf4b699 * cygwin.din: Export the new functions.
* pthread.cc (pthread_cond_*): Add wrapper functions that call __pthread_cond*
functions.
* thread.cc (__pthread_cond_*): Implement the pthread_cond* functions.
* thread.h: Add new class entries and prototypes for __pthread_cond* functions.
* include/pthread.h: user land header prototypes for pthread_cond* functions
and related defines.
2001-03-17 01:14:58 +00:00
Corinna Vinschen e212576dba * environ.cc (parse_options): Use strtok_r instead of strtok.
* security.cc (convert_string_sid_to_sid): Ditto.
        (aclfromtext): Ditto. Fix buffer usage.
2001-03-14 15:32:49 +00:00
Corinna Vinschen 78d2c08cd9 * path.cc (lnk_suffixes): Remove.
(class suffix_scan): Add `lnk_state' flag.
        (suffix_scan::lnk_match): Return state of `lnk_state' now.
        (suffix_scan::has): Changed behaviour if file has `.lnk' suffix.
        (suffix_scan::next): Set `lnk_state' where appropriate.
        (symlink_info::check): Fix a wrong `break'.
        * syscalls.cc (chown_worker): Change debug statement to reflect
        lchown fix.
        (lchown): Call chown_worker with `PC_SYM_NOFOLLOW' instead of
        `PC_SYM_IGNORE'.
2001-03-14 11:13:46 +00:00
Corinna Vinschen 1d39c83a32 * fhandler.cc (fhandler_disk_file::fstat): Add correct modes to
symlinks when stat'ing on FAT or FAT32 file systems.
2001-03-13 13:07:15 +00:00
Earnie Boyd ce2924faee * include/wingdi.h: (DOCINFO) Ansi version defined incorrectly.
Thanks to: Mattia Barbon <mbarbon@dsi.unive.it>
2001-03-13 12:04:57 +00:00
Egor Duda 344ce60cfb Fix typo 2001-03-13 07:58:29 +00:00
Egor Duda e935fcf08a * fhandler.h (fhandler_termios::fixup_after_exec): New function.
* fhandler.cc (fhandler_termios::fixup_after_fork): New function.
Fixup output handle.
* fhandler_tty.cc (fhandler_tty_common::fixup_after_fork): Output
handle is now fixed up in fhandler_termios::fixup_after_fork().
2001-03-12 21:27:42 +00:00
Egor Duda 79409dc0a2 * fhandler.h (fhandler_termios::fhandler_termios): Enable fixup
after fork.
* fhandler_console.cc (fhandler_console::fhandler_console): Fixup
after fork is now enabled in the base class constructor.
2001-03-12 20:39:40 +00:00
Earnie Boyd 17bd7f5a37 * include/commctrl.h (TBSTYLE_FLAT): New definition.
(TB_GETBUTTONSIZE): Ditto.
	(TCS_HOTTRACK): Ditto.
	Thanks to: Chris Hansen <popeofpop@softhome.net>
2001-03-12 19:26:16 +00:00
Christopher Faylor 2b777e2e94 * mkvers.sh: Include config.h so that DEBUGGING is correctly defined. 2001-03-12 16:20:30 +00:00
Christopher Faylor 941fa5ad96 * spawn.cc (spawn_guts): Don't set EXIT_REPARENTING if parent process is not a
cygwin process (suggested by Jason Gouger <cygwin@jason-gouger.com>).
2001-03-12 14:49:29 +00:00
Christopher Faylor d0909d913a * child_info.h: Bump magic number for fork/exec/spawn. 2001-03-11 21:05:49 +00:00
Christopher Faylor abb88b6f53 Remove obvious brain freeze problem. 2001-03-11 16:46:28 +00:00
Christopher Faylor 2116a17508 * autoload.cc (noload): Use proper method for multiline strings or newer gcc's
complain.
* exceptions.cc (unused_sig_wrapper): Ditto.
* fhandler.h (fhandler_base): Make get_io_handle and friends return self.
* fhandler_tty.cc (fhandler_pty_common::close_on_exec): Accomodate DEBUGGING
flag to avoid spurious warnings when inheritance is set.
2001-03-11 01:58:23 +00:00