Commit Graph

5186 Commits

Author SHA1 Message Date
Christopher Faylor 882a0c8507 remove unneeded blank line 2005-02-28 01:55:45 +00:00
Christopher Faylor 9dc6005ae2 * regtool.cc (opts): The argument to 'K' is not optional.
(main): Revert previous change.  Just let getopt deal with missing argument.
2005-02-27 17:55:54 +00:00
Christopher Faylor 2391eea57e * regtool.cc (main): Avoid a SEGV when nothing follows -K. 2005-02-27 06:10:58 +00:00
Christopher Faylor d61925786a * sigproc.cc (_pinfo::set_ctty): Move function
* pinfo.cc (_pinfo::set_ctty): to here.
* fhandler_mem.cc (fhandler_dev_mem::fstat): Don't fill out structure if this
is an on-disk device rather than an "auto" device.
* fhandler_raw.cc (fhandler_dev_raw::fstat): Ditto.
* path.cc (normalize_posix_path): Don't treat a standalone '//' as introducing
a UNC path.
(normalize_win32_path): Ditto.
2005-02-27 04:30:08 +00:00
Christopher Faylor 78d9eaa5ea * kill (getsig): Avoid buffer overflow when generating a signal name.
* strace.cc (handle_output_debug_string): Make error a little more specific.
2005-02-27 03:03:19 +00:00
Christopher Faylor 1a9a235a5a * debug.cc (delete_handle): Report on handle value in debugging output.
* pinfo.h (_pinfo::exists): Declare "new" function.
(_pinfo::kill): Ditto.
* fhandler_termios.cc (tty_min::kill_pgrp): Use _pinfo::exists rather than
proc_exists.
* pinfo.cc (pinfo::init): Ditto.  Don't do a low_priority_sleep(0) when looping
to find exec'ed procinfo.
(pinfo::release): Be more careful about unmapping and closing.
* signal.cc (_pinfo::kill): Rename from kill_worker.  Accommodate entry into
_pinfo class.
(kill0): Use _pinfo::kill rather than kill_worker.
(kill_pgrp): Ditto.  Use _pinfo::exists rather than proc_exists.
* sigproc.cc (_pinfo::exists): Rename from proc_exists.
(pid_exists): Use _pinfo::exists rather than proc_exists.
(remove_proc): Ditto.
* sigproc.h (proc_exists): Delete declaration.
2005-02-26 20:50:25 +00:00
Corinna Vinschen 6d11044c63 * fhandler.h (class fhandler_base): Declare fixup_mmap_after_fork
with additional flags parameter.  Change offset parameter to _off64_t.
	(class fhandler_disk_file): Ditto.
	(class fhandler_dev_mem): Ditto.
	* fhandler_mem.cc (fhandler_dev_mem::fixup_mmap_after_fork):
	Accomodate new parameters.
	* mmap.cc: Include ntdll.h.
	(class mmap_record): Add flags member.
	(mmap_record::mmap_record): Add flags parameter.
	(mmap_record::get_flags): New method.
	(class map): Add next_anon_addr member to store next anonymous mapping
	address suggestion.
	(map::get_next_anon_addr): New method.
	(map::set_next_anon_addr): New method.
	(mmap64): Don't align offset and length to granularity in case of
	MAP_ANONYMOUS on NT.  Check for already existing mapping only on 9x.
	Call mmap_record::mmap_record with additional flags argument.
	(fhandler_base::fixup_mmap_after_fork): Accomodate new parameters.
	(fhandler_disk_file::mmap): Use NtMapViewOfSection with
	AT_ROUND_TO_PAGE flag for anonymous mappings on NT.  If addr is NULL,
	try to map adjacent to previous mapping.
	(fhandler_disk_file::fixup_mmap_after_fork): Add flags argument.
	Change offset parameter to _off64_t.  Use NtMapViewOfSection to
	re-create anonymous mappings on NT.
	(fixup_mmaps_after_fork): Accomodate new parameters when calling
	fhandler's fixup_mmaps_after_fork function.
	* ntdll.h (AT_ROUND_TO_PAGE): New define.
2005-02-25 21:23:15 +00:00
Corinna Vinschen 99e281eb19 * Fix ChangeLog entries. 2005-02-25 11:48:02 +00:00
Corinna Vinschen a3079b47fe * mmap.cc (mmap64): Handle MAP_FIXED request on non-granulation
boundary.
2005-02-25 11:47:17 +00:00
Corinna Vinschen c68de3a262 * mmap.cc (class mmap_record): Declare new map_pages method with
address parameter.
	(mmap_record::map_pages): New method with address parameter.
	(mmap64): Evaluate access mode before checking if already existing
	mapping can be used.
	Only use existing mapping if requested access mode matches the one
	in the existing mapping.
	Add check for existing mapping for MAP_FIXED case.
2005-02-25 11:15:22 +00:00
Danny Smith 078f08b81a * include/wctype.h (wctrans) Remove _CRTIMP.
(towctrans): Likewise.
	(wctype): Likewise,
2005-02-25 08:15:46 +00:00
Danny Smith b7c201d588 * include/wctype.h: Add comment on wctrans, towctrans, wctype. 2005-02-25 01:48:38 +00:00
Danny Smith 7e9439a0eb * mingwex/wctype.c: New file.
* mingwex/wctrans.c: New file.
	* mingwex/Makefile.in (DISTFILES): Add wctype.c, wctrans.c.
	* mingwex/Makefile.in (Q8_OBJS): Add wctype.o, wctrans.o.
2005-02-25 01:43:43 +00:00
Joshua Daniel Franklin f6dbe3872a *README: New file. 2005-02-24 05:26:33 +00:00
Joshua Daniel Franklin 4c6344923e * cygpath.cc (usage): Clarify help output to indicate acceptance
of multiple file names as arguments.
2005-02-24 04:32:45 +00:00
Corinna Vinschen d0578adf88 * localtime.cc: Implement setting __tzrule's offset member using
newlib's __gettzinfo () interface.
	(__tzrule): Remove.
	(timezone): Define as long according to POSIX.
2005-02-23 22:17:28 +00:00
Corinna Vinschen ee8d935cdd * devices.cc: Regenerate. 2005-02-23 22:14:40 +00:00
Corinna Vinschen 3a021c19f4 * devices.in (parsedisk): Fix typo. 2005-02-23 17:59:04 +00:00
Corinna Vinschen c8b404bf5c * cygwin.din (getpeereid): Export.
* fhandler.h (class fhandler_socket): Add pipe and id members to
	exchange eid credentials for AF_LOCAL sockets.
	(eid_pipe_name): Declare new method.
	(getpeereid): Ditto.
	* fhandler_socket.cc (fhandler_socket::eid_pipe_name): New method.
	(fhandler_socket::fhandler_socket): Initialize sec_pipe.
	(fhandler_socket::connect): Exchange eid credentials with accepting
	socket process.
	(fhandler_socket::listen): Prepare eid credential transaction.
	(fhandler_socket::accept): Exchange eid credentials with connecting
	socket process.
	(fhandler_socket::close): Close eid credentials pipe if open.
	(fhandler_socket::getpeereid): New method.
	* net.cc (cygwin_getsockopt): Add SO_PEERCRED handling.
	(getpeereid): New function.
	* include/asm/socket.h (SO_PEERCRED): Define.
	* include/cygwin/socket.h (struct ucred): Define new type.
	* include/cygwin/version.h: Bump API minor version.
2005-02-23 17:39:46 +00:00
Corinna Vinschen 81d0376064 * include/sys/statvfs.h (ST_RDONLY): Define.
(ST_NOSUID): Define.
2005-02-23 16:27:54 +00:00
Corinna Vinschen a652e6d52a * cygwin.din (fstatvfs): Export.
(statvfs): Export.
	* syscalls.cc: Include sys/statvfs.h.
	(statvfs): New function.  Move statfs functionality here.
	(fstatvfs): New function.
	(statfs): Just call statvfs and copy structure.  Check validity of
	incoming struct statfs pointer.
	* include/cygwin/types.h (fsblkcnt_t): Define.
	(fsfilcnt_t): Define.
	* include/cygwin/version.h: Bump API minor version.
	* include/sys/statvfs.h: New file.
2005-02-23 13:12:43 +00:00
Corinna Vinschen e5ef74dfb2 * devices.h: Switch FH_ZERO and FH_PORT as on Linux. Add FH_FULL.
* devices.in: Add /dev/full.
	* devices.cc: Regenerate.
	* dtable.cc (build_fh_pc): Add FH_FULL.
	* fhandler.cc (fhandler_base::fstat): Set FH_FULL permission bits
	correctly.
	* fhandler_zero.cc (fhandler_dev_zero::write): Set errno to ENOSPC
	and return -1 if device is FH_FULL.
2005-02-23 12:30:31 +00:00
Christopher Faylor d1b941af91 * fhandler_disk_file.cc (fhandler_cygdrive::closedir): Return 0 when closing
cygdrive_root.
2005-02-23 02:00:48 +00:00
Corinna Vinschen 24e8fc6872 * cygwin.din (basename): Export.
(dirname): Export.
	* path.cc (basename): New function.
	(dirname): New function.
	* include/libgen.h: New file.
	* include/cygwin/version.h: Bump API minor version.
2005-02-22 19:45:41 +00:00
Corinna Vinschen 156d93af29 * select.cc (peek_pipe): Disable new pipe code until there's
a working substitute.
2005-02-22 15:39:45 +00:00
Corinna Vinschen 9ba51f6d17 * include/cygwin/version.h: Fix comment. 2005-02-22 15:35:10 +00:00
Corinna Vinschen a62f6b806e * cygwin.din (fdatasync): Export.
* fhandler.cc (fhandler_base::fsync): Return with EINVAL if no
	handle is available.
	* syscalls.cc (fdatasync): Create export alias to fsync.
	* include/cygwin/version.h: Bump API minor version.
2005-02-22 15:30:09 +00:00
Corinna Vinschen 4e5a3fa5e2 * fhandler.h (fhandler_base::fstat_helper): Declare with additional
dwVolumeSerialNumber argument.  Drop default values for last three
	arguments.
	* fhandler_disk_file.cc (fhandler_base::fstat_by_handle): Pass
	dwVolumeSerialNumber from GetFileInformationByHandle to fstat_helper.
	(fhandler_base::fstat_by_name): Pass pc.volser () to fstat_helper.
	Accomodate dropping default values for last three arguments of
	fstat_helper.
	(fhandler_base::fstat_helper): Add dwVolumeSerialNumber argument.
	Use for st_dev member unless 0 in which case pc.volser () is used.
2005-02-20 16:14:53 +00:00
Corinna Vinschen 4944ca2f09 * autoload.cc (FindFirstVolumeA): Add.
(FindNextVolumeA): Add.
	(FindVolumeClose): Add.
	(GetVolumePathNamesForVolumeNameA): Add.
	* fhandler.h (class fhandler_base): Declare new method fsync.
	* fhandler.cc (fhandler_base::fsync): New method.
	* syscalls.cc (fsync): Move functionality into fhandler method fsync.
	Just call this method from here.
	(sync_worker): New static function.
	(sync): Fill with life for NT systems.
	* wincap.h (wincaps::has_guid_volumes): New element.
	* wincap.cc: Implement above element throughout.
2005-02-20 13:28:23 +00:00
Corinna Vinschen 2b09be25a3 * fhandler.h (enum query_state): Add query_write_attributes state.
(fhandler_base::status.query_open): Add a bit to make room for more
	states.
	(class fhandler_base): Declare new method utimes.
	(class fhandler_socket): Ditto.
	(class fhandler_disk_file): Ditto.
	(fhandler_disk_file::fhandler_disk_file): Add constructor with
	path_conv parameter.
	* fhandler.cc (fhandler_base::open): Add query_write_attributes
	handling.
	(fhandler_base::utimes): New method.
	* fhandler_disk_file.cc (fhandler_disk_file::link): Simplify.
	Open file with query_write_attributes instead of query_write_control.
	(fhandler_disk_file::utimes): New method.
	(fhandler_disk_file::fhandler_disk_file): Add constructor with
	path_conv parameter setting pc member immediately.
	* fhandler_socket.cc (fhandler_socket::fchmod): Use new
	fhandler_disk_file constructor.
	(fhandler_socket::fchown): Ditto.
	(fhandler_socket::facl): Ditto.
	(fhandler_socket::link): Ditto.
	(fhandler_socket::utimes): New method.
	* times.cc: Include dtable.h.
	(timeval_to_filetime): Make non-static.
	(utimes): Move functionality into fhandler method utimes. Just call
	this method from here.
	* winsup.h: Simplify declarations of time helper functions.
	(timeval_to_filetime): Add extern declaration.
2005-02-20 11:44:32 +00:00
Christopher Faylor 731028b326 copyright 2005-02-20 04:25:33 +00:00
Corinna Vinschen 0d75ce965c * fhandler.h (class fhandler_base): Declare new method link.
(class fhandler_socket): Ditto.
	(class fhandler_disk_file): Ditto.
	* fhandler.cc (fhandler_base::open): Add FILE_WRITE_ATTRIBUTES
	to query_write_control access flags.
	(fhandler_base::link): New method.
	* fhandler_disk_file.cc (fhandler_disk_file::fchmod): Don't try to
	open with O_WRONLY since query_write_control includes
	FILE_WRITE_ATTRIBUTES.
	(fhandler_disk_file::fchown): Ditto.
	(fhandler_disk_file::facl): Ditto.
	(fhandler_disk_file::link): New method.  Touch st_ctime on successful
	link.
	* fhandler_socket.cc (fhandler_socket::link): New method.
	* syscalls.cc (link): Move functionality into fhandler method link.
	Just call this method from here.
2005-02-19 21:53:36 +00:00
Corinna Vinschen c2d0b9d89a * fhandler.h (class fhandler_socket): Declare new methods fchown,
fchmod and facl.
	* fhandler_socket.cc (fhandler_socket::fstat): Handle AF_LOCAL
	sockets.
	(fhandler_socket::fchmod): New method.
	(fhandler_socket::fchown): New method.
	(fhandler_socket::facl): New method.
2005-02-19 20:03:18 +00:00
Corinna Vinschen 2d7606a594 * localtime.cc: Temporary implementation of setting __tzrule's offset
member to be used by strftime.
	(__tzrule): New global variable.
	(tzparse): Set __tzrule's offset member appropriately.
2005-02-19 19:58:38 +00:00
Christopher Faylor 2cd6f872f3 * path.cc (path_conv::check): Set fs flag when a unix-domain socket is
detected.
2005-02-17 17:21:11 +00:00
Corinna Vinschen 3419b5bc2b * fhandler_disk_file.cc (fhandler_disk_file::fstat): Set st_ctime if
has_changed flag is set.
	(fhandler_disk_file::touch_ctime): Reset has_changed flag on success.
2005-02-17 12:41:49 +00:00
Corinna Vinschen b066a19513 * times.cc (utimes): Open files with FILE_WRITE_ATTRIBUTES first,
if that fails, try opeing with GENERIC_WRITE.  Fix comments.
2005-02-17 12:08:16 +00:00
Christopher Faylor 031619634c * path.h (path_conv::issocket): Return true if device == FH_UNIX rather than
expecting path_conv to set a flag.
2005-02-16 00:24:38 +00:00
Christopher Faylor 264f41f081 white space 2005-02-13 18:17:29 +00:00
Christopher Faylor ba8c69552f fix typo 2005-02-11 22:26:20 +00:00
Corinna Vinschen 8be730bbb1 * fhandler.cc (fhandler_base::raw_write): Mark as changed on
successful write.
	* fhandler.h (fhandler_base::status_flags): Add 'has_changed' flag.
	* fhandler_disk_file.cc (fhandler_disk_file::fchmod): Call
	fhandler_disk_file's own open and close instead of open_fs and
	close_fs.  Mark as changed on success.
	(fhandler_disk_file::fchown): Ditto.
	(fhandler_disk_file::facl): Ditto.
	(fhandler_disk_file::ftruncate): Ditto.
	(fhandler_base::open_fs): Mark as changed when O_TRUNC flag on existing
	file is set.
	(fhandler_disk_file::close): Set st_ctime if has_changed flag is set.
2005-02-11 15:37:26 +00:00
Christopher Faylor cc9440b6f4 * cygthread.cc (cygthread::release): Reset ev here if it exists.
(cygthread::terminate_thread): Eliminat racy code which reset ev and
thread_sync.  Remove a few nonsensical inuse checks.  Exit at the bottom.
(cygthread::detach): Rewrite to again try to ensure that we don't say we're
signalled when we are not signalled.
* fhandler.cc (fhandler_base::raw_read): Revert to signalling read success
quickly.
* pipe.cc (fhandler_pipe::close): Use base method to close handle.
* sigproc.h (WAIT_SIG_PRIORITY): Just trundle along at normal priority to allow
the pipe thread to do its thing if possible.
* pinfo.h (pinfo::zap_cwd): Declare new function.
(pinfo::zap_cwd): Move 'cd out of the way code' here.
(pinfo::exit): Use it here.
* spawn.cc (spawn_guts): And here.
2005-02-11 15:24:15 +00:00
Corinna Vinschen 199bf79367 * times.cc (utimes): Open files with GENERIC_WRITE on file systems
not supporting ACLs.
2005-02-11 14:27:36 +00:00
Danny Smith 3d11bd3e07 * include/tchar.h (_tstat64, _tstati64): Add Unicode/ANSI mappings. 2005-02-11 07:23:44 +00:00
Danny Smith ecb313ccee * include/assert.h; Remove header guard. undef assert macro.
(_assert): Use __MINGW_ATTRIB_NORETURN define.
2005-02-11 07:17:00 +00:00
Danny Smith e2a12d9f7d Add Changelog entry from last commit. 2005-02-11 07:15:00 +00:00
Danny Smith ba16f5aa83 2005-02-11 Gregory W. Chicares <chicares at cox dot net>
Danny Smith  <dannysmith@users at sourceforge dot net>

	* include/math.h (expm1, expm1f, expmll): Add prototypes.
	* mingwex/Makefile.in (MATH_DISTFILES): Add expm1.c,
	expm1f.c, expm1l.c.
	(MATH_OBJS): Add expm1.o, expm1f.o, expm1l.o.
	* mingwex/math/expm1.c: New file.
	* mingwex/math/expm1f.c: New file.
	* mingwex/math/expm1l.c: New file.
2005-02-11 04:15:17 +00:00
Christopher Faylor ccf32128b3 add missing ChangeLog entry 2005-02-10 18:12:56 +00:00
Christopher Faylor 292a8156c6 * winsup.api/known_bugs.tcl: Remove dup05, fcntl07B, lseek04, select03,
unlink06.
2005-02-10 17:48:30 +00:00
Danny Smith 78a04600f9 2005-02-10 Jiri Malak <Jiri.Malak@iol.cz>
Danny Smith  <dannysmith@users.sourceforge.net>

	* lib/directx/dinput_private.h (ATTRIBUTE_TEXT_SECTION): New
	define for Open Watcom portability.
	* lib/directx/(dinput_joy.c, dinput_joy2.c, dinput_kbd.c,
	dinput_mouse.c, dinput_mouse2.c): Use new macro in definition
	of local c_rgodfDI* objects. Replace .rdata section attribute
	with 'const' keyword in definition of global c_dfDI* objects.
2005-02-10 01:19:43 +00:00
Corinna Vinschen 9631b700f9 * fhandler_disk_file.cc (fhandler_disk_file::ftruncate): Fix checking
lseek return code.
2005-02-09 19:28:06 +00:00
Corinna Vinschen b6bddccad6 * times.cc (timeval_to_filetime): Define first parameter const.
(utimes): Define second parameter to const according to SUSv3.
	(utime): Ditto.
	* include/sys/utime.h (utime) : Change declaration accordingly.
2005-02-08 20:59:41 +00:00
Corinna Vinschen 01d9b1612c * cygthread.cc (cygthread::detach): Just test thread handle after
signal arrived, don't wait infinitely for it.
2005-02-08 16:56:02 +00:00
Christopher Faylor f1256beb92 * pipe.cc (fhandler_pipe::read): Remove hold over from old read_state
implementation.
2005-02-08 16:19:58 +00:00
Danny Smith 681e60c31c 2005-02-07 Danny Smith <dannysmith@users.sourceforge.net>
* include/winioctl.h (IOCTL_VOLUME_BASE,
	IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS, IOCTL_VOLUME_IS_CLUSTERED):
	Copy defines from include/ddk/ntdddvol.h.
	Bug reported to Debian by Anand Kumria  <wildfire at progsoc dot org>
2005-02-07 20:40:32 +00:00
Danny Smith e693472b16 2005-02-07 Danny Smith <dannysmith@users.sourceforge.net>
* include/sys/stat.h (struct stat): Guard with _NO_OLDNAMES.
	* include/wchar.h (struct stat): Likwwise.
	Bug reported to Debian by Anand Kumria  <wildfire@progsoc.org>

	* include/sys/stat.h: Remove empty __STRICT_ANSI__ guard.
2005-02-07 20:18:08 +00:00
Christopher Faylor a694f07970 * net.cc (cygwin_gethostbyname): Be more picky about what's a numeric address
string, and use tls in that case too.
2005-02-07 15:27:40 +00:00
Christopher Faylor bec2abd71e * exceptions.cc: Make windows_system_directory non-static.
* pinfo.cc (pinfo::exit): Change innocuous cd'ed location to one that is more
likely to exist.
2005-02-07 05:28:49 +00:00
Corinna Vinschen 7d880770d3 * path.cc (path_conv::check): Leave symlink expansion loop in case
a not-ENOENT error happens.

	* cygheap.h (cygheap_fdmanip::fhandler_pipe *): New cast operator.
	* pinfo.cc (_pinfo::commune_recv): Add PICOM_PIPE_FHANDLER handling.
	(_pinfo::commune_send): Ditto.
	(_pinfo::pipe_fhandler): New method.
	* pinfo.h (enum picom): Add PICOM_PIPE_FHANDLER.
	(_pinfo::pipe_fhandler): Declare.
	* pipe.cc (fhandler_pipe::open): Rewrite.  Allow to open foreign
	pipe handles.
2005-02-06 11:15:29 +00:00
Christopher Faylor 85a798d6e7 * cygthread.h (cygthread::terminate_thread): Reflect return value.
* cygthread.cc (cygthread::detach): Be more careful about ensuring that sigwait
is properly waited for to avoid later missynchronization.
(cygthread::terminate_thread): Return true if thread was actually terminated
and all handles were closed.
* fhandler_base.cc (fhandler_base::raw_read): Use signal_read_state rather than
raw calls to win32 api.
(fhandler_base::read): Ditto.
* fhandler.h (fhandler_pipe::fixup_after_exec): Use method to create read_state
signalling.
(fhandler_pipe::create): Ditto.
* Makefile.in: Make some more files -fomit-frame-pointer.
2005-02-06 05:04:34 +00:00
Corinna Vinschen 3fd68a6a04 * fhandler.h (fhandler_base::ftruncate): Define new virtual method.
(fhandler_disk_file::ftruncate): Ditto.
	* fhandler.cc (fhandler_base::ftruncate): New method.
	* fhandler_disk_file.cc (fhandler_disk_file::ftruncate): Ditto.
	* syscalls.cc (ftruncate64): Move functionality into fhandlers.
	Call fhandler method from here.
2005-02-02 22:42:06 +00:00
Corinna Vinschen 0763734fd9 * pipe.cc (fhandler_pipe::dup): Fix conditionals in case of error. 2005-02-02 10:09:51 +00:00
Corinna Vinschen 29ce22c955 * times.cc (utimes): Mark st_ctime for update according to SUSv3. 2005-02-02 09:46:52 +00:00
Christopher Faylor 8c96f3fac2 * fhandler_proc.cc (format_proc_partitions): Remove PartitionType check since
it could skip over partitions that are actually interesting.
2005-02-01 17:16:14 +00:00
Christopher Faylor 74d8e12e16 * cygthread.cc (cygthread::terminate_thread): Wait briefly for notification
event in the event that the thread was actually in the process of exiting.
* pipe.cc (fhandler_pipe::dup): read_state is not supposed to be inheritable.
Fix that.
* path.cc (path_conv::check): Set symlen = 0 to avoid a compiler warning.
* devices.h (devices::parsedisk): Declare new function.
* devices.in (devices::parsedisk): Define new function.
* dtable.cc (dtable::init_std_file_from_handle): Use device numbers rather than
name.
* fhandler_proc.cc (format_proc_partitions): Use parsedisk to generate disk
names from numeric codes.  (This was broken on two of my systems previously and
is still broken now)
2005-02-01 16:49:13 +00:00
Corinna Vinschen 01a94cf866 * pipe.cc (fhandler_pipe::open): Allow re-opening of /proc/<pid>/fd
pipes of the current process.
2005-02-01 16:43:29 +00:00
Corinna Vinschen e8309efda5 * fhandler.cc (fhandler_base::get_proc_fd_name): Don't generate
"device:" entry.
	* fhandler.h (fhandler_socket::open): New method.
	(fhandler_pipe::open): New method.
	* fhandler_proc.cc (fhandler_proc::exists): Return -2 in case of
	/proc/self.
	* fhandler_process.cc (fhandler_process::exists): Return -2 in
	case of symlinks, -3 for pipes and -4 for sockets.
	(fhandler_process::fstat): Handle pipes and sockets.
	(fhandler_process::open): Handle opening /proc/<pid>/fd.
	(fhandler_process::fill_filebuf): Generate empty names for
	non exisiting file descriptors.
	* fhandler_socket.cc (fhandler_socket::get_proc_fd_name): Always
	generate "socket:[number]" strings as on Linux.
	(fhandler_socket::open): New method.
	(fhandler_socket::fstat): Always return socket type.
	* path.cc (symlink_info::set): Remove unused second parameter.
	(path_conv::check): Handle pipes and sockets in /proc.
	Set correct device type for AF_LOCAL sockets.
	* pinfo.cc (_pinfo::commune_recv): Generate empty names for
	non exisiting file descriptors.
	(_pinfo::fd): Ditto.
	* pipe.cc (fhandler_pipe::open): New method.
2005-02-01 15:11:47 +00:00
Danny Smith d93998b17a * mingwex/strtold.c (__asctoe64): Set endptr to 'e' if exponent
string is not valid.
2005-02-01 03:51:21 +00:00
Christopher Faylor 17dc5be5e9 * path.h (path_conv::set_name): Declare new function.
* path.cc (path_conv::set_name): Define new function.
* fhandler.h (fhandler_dev_null::open): Declare new function.
* fhandler.cc (fhandler_dev_null::open): Define new function.
2005-01-31 21:29:59 +00:00
Christopher Faylor 4faae8d6e9 * smallprint.c (rnarg): Use long rather than unsigned long so that we get
proper sign extension.
2005-01-31 20:55:33 +00:00
Corinna Vinschen c93b32d9bf * cygwinenv.sgml: Add words for (no)traverse option. 2005-01-31 20:03:20 +00:00
Corinna Vinschen 740760ec5a * environ.cc (set_traverse): New function.
(parse_thing): Add "traverse" option.  Sort options alphabetically.
	(environ_init): On NT, switch on traverse checking by default.
2005-01-31 20:02:36 +00:00
Christopher Faylor 2b4d82482c * smallprint.c (__rn): Regparmize. 2005-01-31 19:57:05 +00:00
Christopher Faylor 01d13d44fb * smallprint.c (rnarg): New macro.
(rnargLL): Ditto.
(__rn): Rename from 'rn', add a mask argument, and use the mask argument to
control how many significant digits to care about.
(__small_vsprintf): Use __rn, rnarg, rnargLL, as appropriate.
2005-01-31 19:52:03 +00:00
Christopher Faylor ad1d82b851 * pinfo.cc (pinfo::exit): Only return low-order 16 bits when exiting. 2005-01-31 14:34:07 +00:00
Corinna Vinschen 6d336c0e5a * fhandler_process.cc (format_process_maps): Get destbuf argument by
reference.  Allow resizing of destbuf as necessary.  Fix string
	handling.
2005-01-31 12:02:07 +00:00
Corinna Vinschen 4f27e288c5 * cygheap.h (class cygheap_fdenum): New class to enumerate used
fhandlers.
	* dtable.h (class dtable): Add cygheap_fdenum as friend class.
	* fhandler.h (fhandler_base::get_proc_fd_name): New virtual method
	to return a name for /proc/<pid>/fd.
	(fhandler_socket::get_proc_fd_name): Ditto.
	(fhandler_pipe::get_proc_fd_name): Ditto.
	(fhandler_virtual::opendir): Make virtual method.
	(fhandler_process::opendir): New method.
	* fhandler.cc (fhandler_base::get_proc_fd_name): New method.
	* fhandler_process.cc: Include ctype.h.
	(PROCESS_FD): Define.
	(process_listing): Add "fd".
	(fhandler_process::exists): Fix comment.  Return 1 in case of "fd"
	directory. Handle files below "fd".
	(fhandler_process::fstat): Drop "self" handling.  Set correct link
	count for directories.
	(fhandler_process::opendir): New method to handle "fd" directory.
	(fhandler_process::readdir): Add "fd" handling.
	(fhandler_process::open): Drop "self" handling.
	(fhandler_process::fill_filebuf): Ditto.  Add "fd" handling.  Fix
	"maps" output string.
	* fhandler_registry.cc (fhandler_registry::fstat): Set correct link
	count for directories.
	* fhandler_socket.cc (fhandler_socket::get_proc_fd_name): New method.
	* path.cc (symlink_info::set): Fix thinko.
	* pinfo.cc (_pinfo::commune_recv): Rename pathbuf to path throughout.
	Drop local path variable in PICOM_FIFO case.  Fix debug output.
	Close handles as early as possible. Add PICOM_FDS and PICOM_FD
	handling.
	(_pinfo::commune_send): Add PICOM_FDS and PICOM_FD handling.
	(_pinfo::fd): New method.
	(_pinfo::fds): New method.
	* pinfo.h (enum picom): Add PICOM_FDS and PICOM_FD.
	(_pinfo::fd): Declare.
	(_pinfo::fds): Declare.
	* pipe.cc (fhandler_pipe::get_proc_fd_name): New method.
2005-01-31 10:28:55 +00:00
Joshua Daniel Franklin d0ae095b8c * ntsec.sgml: Add Pierre's Windows 2003 text. 2005-01-29 22:35:17 +00:00
Corinna Vinschen e86f8b7925 * smallprint.c (rn): Change uval to unsigned long long to fix 64 bit
handling.
	* fhandler_process.cc (format_process_maps): Print major, minor and
	inode numbers correctly.
2005-01-29 13:34:34 +00:00
Corinna Vinschen faf07ace92 * autoload.cc (GetModuleFileNameExA): Add.
(GetModuleInformation): Add.
	(QueryWorkingSet): Add.
	* fhandler.h (fhandler_virtual::get_filebuf): New method.
	* fhandler_proc.cc (PROC_SELF): Define.
	(proc_fhandlers): Change type of self to FH_PROC.
	(fhandler_proc::exists): Return -3 if self.
	(fhandler_proc::fstat): Handle self as symlink.
	(fhandler_proc::fill_filebuf): Handle self.
	* fhandler_process.cc: Include psapi.h.
	(PROCESS_EXENAME): Remove.
	(PROCESS_MAPS): Define.
	(PROCESS_ROOT): Define.
	(PROCESS_EXE): Define.
	(PROCESS_CWD): Define.
	(process_listing): Remove "exename", add "maps, "root", "exe" and
	"cwd" elements.
	(fhandler_process::exists): Return -2 for symlinks.
	(fhandler_process::fstat): Handle symlinks.
	(fill_filebuf): Evaluate pid if pid is 0.  Use exename handling for
	exe.  Handle maps, root and cwd.
	(format_process_maps): New function evaluating "maps".
	* path.cc (symlink_info::set): New method to fill symlink_info
	with data matching virtual symlinks.
	(path_conv::check): Handle virtual symlinks.
	* pinfo.cc (_pinfo::commune_recv): Add PICOM_CWD and PICOM_ROOT
	handling.
	(_pinfo::commune_send): Ditto.
	(_pinfo::root): New function.
	(_pinfo::cwd): New function.
	* pinfo.h (enum picom): Add PICOM_CWD and PICOM_ROOT.
	(_pinfo::root): Declare.
	(_pinfo::cwd): Declare.
2005-01-29 11:23:07 +00:00
Christopher Faylor 2eeb0e70a3 * cygthread.cc (new): Add a little more debugging.
* thread.cc (pthread_null::exit): Add a _my_tls.remove() for safety.
2005-01-29 05:39:07 +00:00
Christopher Faylor 02e221b774 * cygtls.cc (cygtls::call2): Move socket cleanup.
(cygtls::remove): Move socket cleanup here.  Don't use _my_tls to reference it.
2005-01-29 03:09:50 +00:00
Corinna Vinschen 0eefa5256b * how-using.texinfo: Change text about using shortcuts. 2005-01-28 09:10:22 +00:00
Christopher Faylor 02da559a0b . 2005-01-28 05:53:22 +00:00
Danny Smith 8cc85fff15 2005-01-27 Oliver Stoeneberg <oliverst@online.de>
* include/winbase.h (PWIN32_FIND_DATA): Add typedef.
2005-01-27 21:04:18 +00:00
Danny Smith 93b96855f4 2005-01-26 Oliver Stoeneberg <oliverst@online.de>
* include/malloc.h: Add missing return code defines for
	_heapwalk()
2005-01-27 00:34:42 +00:00
Christopher Faylor 325eadaa57 * pinfo.cc (pinfo::init): Avoid a compiler warning. 2005-01-26 18:21:22 +00:00
Corinna Vinschen 0f72b90637 * syscalls.cc (setpriority): Implement PRIO_PGRP, PRIO_USER and
setting priority in other Cygwin processes.
	(getpriority): Implement PRIO_PGRP, PRIO_USER and getting nice value
	from other processes.
2005-01-26 13:07:48 +00:00
Danny Smith b7a51e1b2a * include/winuser.h (SW_SMOOTHSCROLL): Add define. 2005-01-26 06:25:59 +00:00
Pierre Humblet 9df58602b6 2005-01-26 Pierre Humblet <pierre.humblet@ieee.org>
* path.cc (path_conv::check): Return ENOTDIR rather than ENOENT
	when a component is not a directory. Remove unreachable code.
	(digits): Delete.
2005-01-26 04:34:19 +00:00
Christopher Faylor 0e32d1ffcd * pinfo.h (pinfo::init): Make third parameter non-optional and propagate change
throughout.
* pinfo.cc (set_myself): Pass INVALID_HANDLE_POINTER if h is NULL.
(pinfo::init): Make third parameter non-optional.  Eliminate use of PID_EXECED
as an argument.  Put setting of handle back inside loop but reorganize to try
to open it only when necessary.
2005-01-26 00:15:11 +00:00
Corinna Vinschen 72c1491bba * cygwin.din: Export getpriority and setpriority.
* fork.cc (fork_parent): Copy parent's nice value into child.
	* spawn.cc (spawn_guts): Ditto.
	* miscfuncs.cc (winprio_to_nice): New function.
	(nice_to_winprio): Ditto.
	* pinfo.cc (pinfo_init): If parent is not a Cygwin process, set
	default nice value according to current Win32 priority class.
	* pinfo.h (class _pinfo): Add nice member.
	* syscalls.cc (setpriority): New function, only implementing
	PRIO_PROCESS for now.
	(getpriority): Ditto.
	(nice): Just call setpriority.
	* wincap.h (wincaps::has_extended_priority_class): New element.
	* wincap.cc: Implement above element throughout.
	* winsup.h: Add prototypes for winprio_to_nice and nice_to_winprio.
	* include/limits.h (NZERO): New define.
	* include/cygwin/types.h (id_t): New datatype.
	* include/cygwin/version.h: Bump API minor version.
	* include/sys/resource.h: Add PRIO_XXX defines and prototypes for
	getpriority and setpriority.
2005-01-25 22:45:11 +00:00
Corinna Vinschen 17923424c4 * path.cc (realpath): Allow to expand with .exe suffix. 2005-01-25 20:28:40 +00:00
Joshua Daniel Franklin 12ff82d08e * install.texinfo: Add live CD, registry information. 2005-01-22 23:39:37 +00:00
Christopher Faylor c75e4f09ec * spawn.cc (spawn_guts): Perform same "cd" as in pinfo::exit below to make sure
that a stub process does not keep the current working directory busy after the
"execed" process has exited.
2005-01-22 21:47:04 +00:00
Christopher Faylor 9a0b76dced * pinfo.cc (pinfo::init): Move everything but the MapViewOfFileEx out of the
loop since trying multiple times to call CreateFileMapping doesn't make much
sense.  Try to structure the loop a little better so that exiting with a break
does the right thing.
(pinfo::release): Release shared memory area if it exists and close handle if
it exists.
2005-01-22 21:17:53 +00:00
Joshua Daniel Franklin 672879cab6 * how-programming.texinfo: Add details about building a debugging version of the DLL.
* how-using.texinfo: Correct rxvt README location.
* install.texinfo: Add mount -m note to uninstall instructions.
2005-01-22 19:12:33 +00:00
Christopher Faylor 4c133af135 * pinfo.cc (pinfo::maybe_set_exit_code_from_windows): Make sure that process
has exited before getting an error code.
(pinfo::exit): "cd" to innocuous location before exiting to make sure that
process does not keep the current working directory busy while it is in the
process of really exiting.
2005-01-22 18:07:10 +00:00
Christopher Faylor f2d6aeea17 * how-programming.texinfo: Remove obsolete w32api instructions and add some
words about unpacking net release .tar.bz2.
2005-01-22 03:53:38 +00:00
Chris Sutcliffe ea27b6f219 2005-01-21 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* include/commdlg.h (OFN_DONTADDTORECENT): Added definition.
2005-01-21 13:39:35 +00:00
Corinna Vinschen c20ec37fbd * autoload.cc (CoInitialize): Remove.
(CoUninitialize): Remove.
	(CoCreateInstance): Remove.
	(CoTaskMemFree): Add.
	(SHGetDesktopFolder): Add.
	* path.cc (shortcut_header): Remove.
	(shortcut_initalized): Remove.
	(GUID_shortcut): New static GUID.
	(struct win_shortcut_hdr): New struct describing Windows shortcut
	header structure.
	(symlink_worker): Rewrite creating Windows shortcuts.  Create
	ITEMIDLIST if target exists.  Only write once.
	(cmp_shortcut_header): Use win_shortcut_hdr structure for comparison.
	(check_shortcut): Rewrite to read only once from file.  Allow skipping
	an ITIMIDLIST in the file.
2005-01-18 13:00:18 +00:00
Danny Smith 4d6b4804e9 * lib/user32.def (MonitorFromPoint}: Correct suffix. 2005-01-18 07:14:54 +00:00
Danny Smith 4c9f0d3547 * include/sys/stat.h (struct __stat64): Change st_size type to
__int64.
	* include/wchar.h (struct __stat64): Change st_size type to __int64.
2005-01-17 05:03:17 +00:00
Christopher Faylor 37d5841f83 * pinfo.h (maybe_set_exit_code_from_windows): Renamed from set_exit_state.
* pinfo.cc (pinfo::exit): Use renamed function.
(proc_waiter): Ditto.  Make a copy of input argument to avoid problems when
procs array is shuffled.  Flag when copy is made so that remove_proc knows when
it is safe to reshuffle.
* sigproc.cc (proc_terminate): Don't flag process_state as PID_EXITED.
(remove_proc): Wait for waiter to finish copying pinfo element before moving it
(an actual wait should be an extremely rare event).
2005-01-17 04:12:08 +00:00
Christopher Faylor 459a956197 * ps.cc (main): Eliminate use of PID_ZOMBIE.
* strace.cc (main): Recognize new option for displaying hex value of strace
type.
(handle_output_debug_string): Prepend output with hex value of strace message
if -H is specified.
2005-01-16 17:13:51 +00:00
Christopher Faylor 85b3fb9640 * init.cc (dll_entry): Remove unused extern.
* include/sys/cygwin.h: Remove PID_ZOMBIE.
* pinfo.h: Rename EXITCODE_* defines.
(pinfo::set_exit_state): Remove parameter.
* pinfo.cc (set_exit_state): Remove parameter.  Reverse sense of test so that
exitcode is checked for having been set rather than not having been set.  Set
flag when exitcode has been established.  Don't set PID_STATE here.
(pinfo::init): Remove exitcode initialization.
(pinfo::exit): Reflect change in EXITCODE_* naming.  Set flag when exitcode has
been established.  Reflect change in arguments to set_process_state.
(proc_waiter): Reflect change in arguments to set_process_state.  Set
process_state here and only here.
* fhandler_process.cc (fhandler_process::fill_filebuf): Reflect removal of
PID_ZOMBIE define.
(format_process_stat): Ditto.
(format_process_status): Ditto.
* sigproc.cc (pid_exists): Ditto.
(stopped_or_terminated): Ditto.  Make sure that only low-order 16 bits of
exitcode are used.
* spawn.cc (spawn_guts): Reflect change in EXITCODE_* naming.
2005-01-16 17:00:27 +00:00
Christopher Faylor fdd857a1f6 * sigproc.cc (sig_send): Don't complain if attempt to send signal to myself
fails after I've "execed".
2005-01-15 23:43:42 +00:00
Corinna Vinschen aafdf30f7a * fhandler_disk_file.cc (fhandler_disk_file::facl): Pretend successful
SETACL if no acls are available.
	* fhandler.cc (fhandler_base::facl): Implement to return sensible
	values on GETACL and GETACLCNT.  Pretend successful SETACL.
	* fhandler_virtual.cc (fhandler_virtual::facl): Ditto.
2005-01-14 22:03:40 +00:00
Corinna Vinschen 36ca239fd4 * fhandler.h (fhandler_disk_file::touch_ctime): Declare.
* fhandler_disk_file.cc (fhandler_disk_file::touch_ctime): New method
	to set file's ctime.
	(fhandler_disk_file::fchmod): Try opening file for writing first.
	Set file's ctime on success.
	(fhandler_disk_file::fchown): Ditto.
	(fhandler_disk_file::facl): Ditto.
2005-01-13 22:56:20 +00:00
Corinna Vinschen 0dabe0e0c2 * pinfo.cc (pinfo::exit): Don't access self after releasing it.
* path.h (path_conv::path_conv): Fill path with native device
	name in case of device argument.
2005-01-13 22:18:57 +00:00
Corinna Vinschen 9b8e782e11 * fhandler_serial.cc (fhandler_serial::dup): Call overlapped_setup
for child, not for parent.
2005-01-13 20:10:04 +00:00
Earnie Boyd bfe069a3b0 * include/_mingw.h: Increment version to 3.7.
* Makefile.in: Ditto.
2005-01-13 19:51:02 +00:00
Christopher Faylor a09a6e6838 * init.cc (dll_entry): Nuke attempt to set exit code since parent will use
windows exit code if needed.
* pinfo.cc (pinfo::exit): Move release() here to minimize pid creation race
(suggested by Pierre Humblet).
2005-01-13 16:38:35 +00:00
Earnie Boyd 29de2b1938 * include/sys/stat.h (_S_IFLNK, S_IFLNK, _S_ISLNK, S_ISLNK, _lstat,
lstat): Remove.
	* include/errno.h (ELOOP): Ditto.
2005-01-13 12:40:37 +00:00
Danny Smith 6c03322566 2005-01-13 Benoit Blanchon <bblanchon@users.sourceforge.net>
* include/wininet.h (InternetCheckConnectionA,
	InternetCheckConnectionW) Add prototypes.
	(INTERNET_RAS_INSTALLED, INTERNET_CONNECTION_OFFLINE,
	INTERNET_CONNECTION_CONFIGURED): Add defines.
2005-01-13 09:14:42 +00:00
Christopher Faylor 169c465a83 Reorganize header file inclusion throughout so that cygerrno.h comes first.
* fhandler.h (select_record::thread_errno): Save any encountered errno here.
(select_record::set_select_errno): New function.
(select_record::saw_error): New function.
(select_record::select_record): Initialize thread_errno to zero.
* select.cc (set_handle_or_return_if_not_open): Set thread_errno on failure.
(select_stuff::wait): Record errno for later resurrection in calling thread.
(peek_serial): Ditto.
2005-01-12 22:40:46 +00:00
Christopher Faylor 066e8c8424 Add missing changelog entry. 2005-01-12 20:06:17 +00:00
Christopher Faylor 48befd8305 * pinfo.cc (pinfo::exit): Don't assume that this == myself. 2005-01-12 18:05:07 +00:00
Danny Smith 49f7830187 * include/tchar.h (_tfreopen): Add UNICODE mappings. 2005-01-12 09:08:12 +00:00
Pierre Humblet 114b7248ee 2005-01-11 Pierre Humblet <pierre.humblet@ieee.org>
* mkpasswd.c (print_win_error): Transform into macro.
        (_print_win_error): Upgrade former print_win_error by
        printing the line.
        (current_user): Call _print_win_error.
        (enum_users): Print name in case of lookup failure.
        (enum_local_groups): Ditto.
2005-01-11 23:03:24 +00:00
Christopher Faylor 7730395470 * pinfo.cc (pinfo::init): Don't close input handle on temporary (?) failure. 2005-01-11 16:58:31 +00:00
Christopher Faylor d1adad9045 revert previous erroneous checkin. 2005-01-11 15:49:17 +00:00
Christopher Faylor 2380dfe14c * pinfo.h (_pinfo::set_exit_state): Declare new function.
(pinfo::exit): Move here from _pinfo::exit.
* sigproc.cc (child_info::sync): Use new function to set exitcode and
process_state.
* pinfo.cc (_pinfo::exit): Ditto.
(proc_waiter): Ditto.
(_pinfo::set_exit_state): Define new function.
(_pinfo::dup_proc_pipe): Close handle when there is no parent process around to
care about the exit value.
* dcrt0.cc (dll_crt0_0): Move subproc_ready synchronization later to make sure
that myself is still mapped in parent.
(do_exit): Reflect movement to pinfo::exit.
(__api_fatal): Ditto.
* exceptions.cc (signal_exit): Ditto.
* errno.cc (errmap): Map PROC_NOT_FOUND.
* init.cc (dll_entry): Release myself before exiting.
* sigproc.cc (proc_can_be_signalled): Set errno appropriately.
(sig_send): Ditto.  Also remove ill-advised test for !myself->sendsig since
this is an indication of a process which is still initializating -- it is not
an error.
(child_info::sync): Don't set exitcode here.  Assume that will happen in
proc_waiter, if necessary.
* spawn.cc (spawn_guts): Delay "wait_for_myself" logic until later.  Don't wait
at all if the process has already exited.  Reflect movement to pinfo::exit.
2005-01-11 15:31:04 +00:00
Earnie Boyd aa67a4484e * include/sys/stat.h (_S_IFLNK, S_IFLNK, _S_ISLNK, S_ISLNK, _lstat,
lstat): Conditionalize defines for __STRICT_ANSI__.
2005-01-11 13:34:42 +00:00
Corinna Vinschen 0e05431799 * ChangeLog: Split and create ChangeLog-2004. 2005-01-11 12:48:34 +00:00
Corinna Vinschen eade2ea557 * environ.cc: Yes, yes, the copyright date, as usual. 2005-01-11 12:45:08 +00:00
Corinna Vinschen d1ce9364f3 * environ.cc (build_env): Disallow empty strings and strings starting
with '=' in Win32 environment.
2005-01-11 12:42:35 +00:00
Earnie Boyd 58bdcd7fc7 * include/errno.h (ELOOP): Add definition. 2005-01-10 21:15:40 +00:00
Corinna Vinschen 0b99127e40 * fhandler_disk_file.cc: Fix copyright date. 2005-01-10 13:09:56 +00:00
Chris Sutcliffe 2201bc5378 2005-01-07 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* include/commctrl.h (ComboBox_SetMinVisible,
	ComboBox_GetMinVisible): Added Macros.
	* include/winuser.h (CB_SETMINVISIBLE, CB_GETMINVISIBLE):
	Added definitions.
2005-01-10 11:59:25 +00:00
Danny Smith 4073a59300 * mingwex/complex/(cabsl.c cacosl.c cacoshl.c cargl.c casinl.c
casinhl.c catanl.c catanhl.c ccosl.c ccoshl.c cexpl.c cimagl.c
	clogl.c cpowl.c cprojl.c creall.c csinl.c csinhl.c csqrtl.c
	ctanl.c ctanhl.c): New files.
	* mingwex/Makefile.in (COMPLEX_DISTFILES): Adjust.
	(COMPLEX_OBJS): Adjust.
	* include/complex.h (cabsl, cacosl, cacoshl, cargl, casinf.
	casinhl, catanl, catanhl, ccosl, ccoshl, cexpl, cimagl, clogl,
	cpowl, cprojl, creall, csinl, csinhl, csqrtl, ctanl, ctanhl):
	Declare.
2005-01-10 05:03:55 +00:00
Christopher Faylor 76eb619239 * cygrun.c (main): Fix exit code so that it reflects UNIX style.
* winsup.api/ltp/fork04.c (setup): Accommodate change in putenv declaration.
2005-01-10 04:13:39 +00:00
Pierre Humblet a6888c92d9 2005-01-08 Pierre Humblet <pierre.humblet@ieee.org>
* syscalls.cc (seteuid32): Only change the default dacl when
	seteuid succeeds. Do not close HKCU.
2005-01-08 18:33:07 +00:00
Corinna Vinschen a3acb4a5ce * fhandler_process.cc: Fix copyright date. 2005-01-07 11:39:52 +00:00
Corinna Vinschen 69008322ef * fhandler_process.cc: Use strcasematch instead of strcasecmp
throughout.
2005-01-06 23:00:08 +00:00
Corinna Vinschen 6e450bdeed * syscalls.cc (rename): Fix behaviour in case of renaming directories
according to SUSv3.
2005-01-06 22:10:08 +00:00
Corinna Vinschen 375c7faa4c * fhandler_disk_file.cc (fhandler_base::open_fs): Don't allow
opening directories for writing.
2005-01-06 17:43:55 +00:00
Christopher Faylor e66b2c9522 update copyright 2005-01-06 16:36:40 +00:00
Christopher Faylor fdb83f2269 * timer.cc (timer_thread): Pass sigev pointer value as per SuSv3 rather than
pointer to sigev.
2005-01-06 14:09:14 +00:00
Danny Smith 23edaf199a * include/_mingw.h (__int16): Define as short. 2005-01-06 11:20:51 +00:00
Danny Smith 5c54e03a27 * include/stdio.h (P_tmpdir): Add define. 2005-01-06 11:10:58 +00:00
Christopher Faylor 2d76a612d2 * dcrt0.cc (multiple_cygwin_problem): Reorganize error message to not always
talk about a "version" when it's not a version.
(dll_crt0_0): Change info passed to multiple_cygwin_problem to be a little more
precise.
* shared.cc (user_shared_initialize): Ditto.
(shared_info::initialize): Ditto.
2005-01-05 21:40:08 +00:00
Christopher Faylor abb13199ba * pinfo.cc (_pinfo::dup_proc_pipe): Can't close proc pipe when execing or we
will suffer an exit code race.
2005-01-04 14:57:42 +00:00
Christopher Faylor dbdbed283b Update copyrights. 2005-01-03 18:16:46 +00:00
Corinna Vinschen 42347b0a3b * signal.cc: Fix copyright date. 2005-01-03 18:11:00 +00:00
Corinna Vinschen 1a063c5030 * signal.cc (abort): Call _GLOBAL_REENT's __cleanup. 2005-01-03 18:06:26 +00:00
Earnie Boyd a6f8d3d6c6 * Makefile.in (inst_docdir): For Cygwin target set to share/doc/. 2005-01-03 16:32:25 +00:00
Corinna Vinschen 26e3b0f006 * syscalls.cc (setmode): Call _fwalk with _GLOBAL_REENT. 2005-01-03 10:59:09 +00:00
Danny Smith 9e5e1983f8 2005-01-02 Jiri Malak <Jiri.Malak@geac.cz>
* include/winnt.h (GetCurrentFiber, GetFiberData): Make inline
	assembly code conditional on _X86_.
2005-01-02 21:46:06 +00:00
Earnie Boyd 97f3a22475 * include/_mingw.h: Increment version to 3.6
* Makefile.in: Ditto
2005-01-02 17:17:17 +00:00
Earnie Boyd 636a3bf5bb * lib/uxtheme.def: Really remove the \r. 2005-01-02 14:15:16 +00:00
Earnie Boyd 94d17419a6 * include/afxres.h: Remove the \r from the line ending.
* include/errorrep.h: Ditto.
	* include/shldisp.h: Ditto.
	* include/tschema.h: Ditto.
	* lib/dhcpcsvc.def: Ditto.
	* lib/uxtheme.def: Ditto.
	* lib/wldap32.def: Ditto.
2005-01-02 14:11:28 +00:00
Earnie Boyd 615c8c8884 * include/w32api.h: Increment version.
* Makefile.in: Ditto.
2005-01-02 13:48:13 +00:00
Christopher Faylor 538776b743 * cygthread.cc (cygthread::stub): Set inuse to false when exiting.
(cygthread::cygthread): Actually pass name as argument to debugging output to
avoid SEGV when strace'ing.
(cygthread::release): Don't set stack_ptr to NULL, since it is only set once on
first entry to a stub not on each stub iteration.
(cygthead::exit_thread): Remove obsolete function.
* cygthread.h (cygthread::exit_thread): Ditto.
2005-01-02 02:22:25 +00:00
Christopher Faylor d8c83adc04 * shared.cc (open_shared): Don't attempt VirtualAlloc magic if first attempt to
map memory fails.
2005-01-02 00:34:55 +00:00
Danny Smith f8316b46dd * include/winerror.h (ERROR_EXE_CANNOT_MODIFY_STRONG_SIGNED_BINARY):
Correct typo.
2005-01-01 08:57:31 +00:00
Joshua Daniel Franklin ede7692fd2 * path.sgml: Encode programming example with CDATA. 2004-12-31 01:13:28 +00:00
Christopher Faylor d89a855e73 * devices.cc (device::isfs): Return true for the logical case of devn == FH_FS. 2004-12-30 16:21:59 +00:00
Corinna Vinschen f312634c02 * bsd_mutex.cc: Include limits.h.
(MSLEEP_MUTEX): New define for third parameter to msleep_event_name.
	(MSLEEP_SEM): Ditto.
	(MSLEEP_EVENT): Ditto.
	(msleep_event_name): Add third parameter to allow multiple
	synchronization objects per ident.
	(_msleep): Implement new synchronization technique to make sure
	that all threads have been woken up by a corresponding wakeup call.
	(wakeup): Ditto.
2004-12-30 15:58:27 +00:00
Chris Sutcliffe 3a39329a25 2004-12-29 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
*include/winuser.h (MNS_*, WM_MENUCOMMAND,
	WM_MENUGETOBJECT, WM_MENUDRAG, WM_NCMOUSEHOVER,
	WM_NCMOUSELEAVE, WM_UNINITMENUPOPUP,
	SPI_GETFOREGROUNDLOCKTIMEOUT,
	SPI_SETFOREGROUNDLOCKTIMEOUT): Added definitions.
	*include/imm.h (WM_IME_REQUEST): Added definition.
	*include/shlobj.h (SLGP_RAWPATH,
	SLGP_UNCPRIORITY): Added definition.
2004-12-29 12:15:19 +00:00
Chris Sutcliffe 5f0fd59974 Added HSHELL_FLASH definition 2004-12-29 00:31:31 +00:00
Christopher Faylor 264a0b2f54 * pinfo.cc (_pinfo::dup_proc_pipe): DUPLICATE_CLOSE_SOURCE closes the handle
regardless, so revert previous change.
2004-12-28 06:07:45 +00:00
Christopher Faylor 57ba174fa0 * cygthread.cc (cygthread::stub): Add better debug output.
(cygthread::cygthread): Ditto.
(cygthread::terminate_thread): Ditto.  Move inuse test earlier or suffer
infinite loop.
* pinfo.cc (_pinfo::dup_proc_pipe): Close handle if DuplicateHandle fails and
process no longer exists.
* spawn.cc (spawn_guts): Create process in suspended state if OS demands it.
* wincap.cc: Add "start_proc_suspended" throughout.
* wincap.h (wincaps): Ditto.
(wincapc): Ditto.
2004-12-28 01:27:26 +00:00
Joshua Daniel Franklin b75ec93a63 Update Makefile to use xmlto 2004-12-27 19:03:56 +00:00
Christopher Faylor 6e3c97b14e * pinfo.cc (_pinfo::exit): Beef up debugging output.
* sigproc.cc (proc_subproc): Detached children apparently need a ppid of 1.
2004-12-27 17:19:25 +00:00
Christopher Faylor 933673e83b * init.cc (dll_entry): Previous code reversion was ill-advised. Revert it.
* sigproc.cc (child_info::sync): Ditto.
* pinfo.cc (_pinfo::exit): Don't set myself.procinfo to NULL since it is no
longer required.
2004-12-27 02:13:30 +00:00
Christopher Faylor 445d5ce8fc * init.cc (dll_entry): Remove exit code setting.
* pinfo.cc (pinfo::init): Initialize exitcode to unset state rather than
SIGTERM.
(proc_waiter): Detect if exit code is unset and use status from
GetExitCodeProcess.
* sigproc.cc (child_info::sync): Remove exit code detection here since
proc_waiter now (again) detects it.
2004-12-27 00:35:19 +00:00
Christopher Faylor 8711eddd80 * fhandler.cc (fhandler_base::fchmod): Do the right thing when changing an "on
disk" device or fifo.
(fhandler_base::fchown): Ditto for changing ownership.
* fhandler_disk_file.cc (fhandler_base::fstat_helper): Accommodate device files
on ntfs partitions.
* path.cc (path_conv::check): Use isfs function to figure out if a path exists
on a filesystem to make sure that device files are caught.
2004-12-26 02:10:30 +00:00
Danny Smith 9a3412eea8 * mingwex/complex/(cabsf.c cacosf.c cacoshf.c cargf.c casinf.c
casinhf.c catanf.c catanhf.c ccosf.c ccoshf.c cexpf.c cimagf.c
	clogf.c cpowf.c cprojf.c crealf.c csinf.c csinhf.c csqrtf.c
	ctanf.c ctanhf.c): New files.
	* mingwex/Makefile.in (COMPLEX_DISTFILES): Adjust.
	(COMPLEX_OBJS(: Adjust.
	* include/complex.h (cabsf, cacosf, cacoshf, cargf, casinf.
	casinhf, catanf, catanhf, ccosf, ccoshf, cexpf, cimagf, clogf,
	cpowf, cprojf, crealf, csinf, csinhf, csqrtf, ctanf, ctanhf):
	Declare.
2004-12-25 23:56:19 +00:00
Joshua Daniel Franklin c98b30eadc * .sgml: Cleanup markup for XML validity. 2004-12-24 21:58:38 +00:00
Christopher Faylor e1736c2f13 * child_info.h (CURR_CHILD_INFO_MAGIC): Update.
(child_info::parent_wr_proc_pipe): Eliminate.
* pinfo.h (_pinfo::alert_parent): Move here from pinfo class.
(_pinfo::dup_proc_pipe): New method.
(_pinfo::sync_proc_pipe): Ditto.
* exceptions.cc (sig_handle_tty_stop): Reflect move of alert_parent.
* init.cc (dll_entry): Exit with status one if main process called ExitProcess.
* pinfo.cc (set_myself): Remove handling of parent_wr_proc_pipe.
(_pinfo::exit): Reflect move of alert_parent.  Set procinfo to NULL to flag
that we are exiting normally.  Always use exitcode when exiting
(although this could be a little racy).
(pinfo::init): Set default exit to SIGTERM.  This will be the exit code
reported if process is terminated.
(_pinfo::dup_proc_pipe): New function.
(pinfo::wait): Duplicate wr_proc_pipe to the right place.  Use dup_proc_pipe to
move the pipe to the child.
(_pinfo::sync_proc_pipe): New function.
(_pinfo::alert_parent): Move to _pinfo.  Make sure that wr_proc_pipe is ours
before using it.
* sigproc.cc (child_info::child_info): Remove handling of parent_wr_proc_pipe.
* spawn.cc (spawn_guts): Pass our wr_proc_pipe to the child when execing.
Ensure that exit code of cygwin process started from windows is correctly set.
2004-12-24 18:31:23 +00:00
Danny Smith 4697fbcd51 2004-12-24 Chris Sutcliffe <ir0nh34d@users.sourceforge.net>
* include/shldisp.h: New file.
	* include/shlobj.h (IObjMgr): Added interface definiton.
	* lib/shell32.c (CLSID_AutoComplete, IID_AutoComplete,
	IID_AutoComplete2, CLSID_ACLMulti, IID_IObjMgr,
	CLSID_ACListISF, IID_IACList): Added GUIDs.
	* include/shlguid.h (CLSID_AutoComplete, IID_AutoComplete,
	IID_AutoComplete2, CLSID_ACLMulti, IID_IObjMgr,
	CLSID_ACListISF, IID_IACList): Added GUIDs.
2004-12-24 11:14:35 +00:00
Christopher Faylor 861ef99725 * path.h (path_conv::set_normalized_path): Add second argument and fill it in
throughout.
* path.cc (path_conv::check): Declare, set and use "strip_tail".
(path_conv::set_normalized_path): Add and use second argument, replacing all
tail stripping tests.
2004-12-23 21:37:44 +00:00
Christopher Faylor 7a2ba9dbec * cygthread.cc (cygthread::cygthread): Guard debugging variable with "ifdef
DEBUGGING".
(cygthread::release): Ditto.
2004-12-23 15:36:59 +00:00
Christopher Faylor aad93aea3e * path.cc (path_conv::check): Don't strip the trailing slash from a path
consisting only of two slashes.
2004-12-23 15:26:38 +00:00
Christopher Faylor 4ee52924a6 * cygthread.cc (cygthread::stub): Detect if thread function wants to release
itself here, to avoid a race.
(cygthread::release): Clear more stuff.  Add a diagnostic for an internal
error.
* cygthread.h (auto_release): New function.
* pinfo.h (pinfo::remember): Add an argument to denote whether child is
detached.
* fork.cc (fork_parent): Reflect change in arguments to pinfo::remember.
* pinfo.cc (_pinfo::exit): Signal exit more forcibly.
(proc_waiter): Use cygthread::auto_release to signify that cygthread::stub
should release the thread.  This should avoid a race.
(pinfo::alert_parent): Don't signify an error when wr_proc_pipe == NULL.
* sigproc.cc (proc_subproc): Add support for PROC_DETACHED_CHILD.
* sigproc.h: Ditto.
* spawn.cc (spawn_guts): Specify whether child is detached or not when calling
pinfo::remember.
2004-12-23 14:57:08 +00:00
Danny Smith 3993374d4e * include/commctrl.h (CDRF_NOTIFYSUBITEMDRAW): Add define.
Thanks to: Chris Sutcliffe  <ironhead@walled.net>
	(CDRF_*): Use hex notation for constants.
2004-12-23 08:13:51 +00:00
Christopher Faylor 63fcc6d48f * cygheap.cc (cygheap_setup_for_child): Add api_fatal to catch failing
MapViewOfFileEx.
* cygthread.cc (cygthread::stub): Previous change to make diagnostic output
more informative was really a bust.  Try again.  Capture previous name in a new
field in cygthread for diagnostic purposes.
(cygthread::cygthread): Ditto.
(cygthread::release): Add an argument to control whether h should be cleared or
not.
(cygthread::terminate_thread): Use 'inuse' for tests rather than 'h'.
(cygthread): Add some diagnostic fields.
(cygthread::release): Add an argument.
* pinfo.cc (proc_waiter): Accommodate change to cygthread::release.
2004-12-22 18:12:30 +00:00
Christopher Faylor 16bd231ec6 * cygthread.cc (cygthread::stub): Make diagnostic output more informative. 2004-12-22 17:10:19 +00:00
Christopher Faylor 9bc36097c9 * pinfo.cc (proc_waiter): Zero wait_thread in child to avoid races with process
termination.
* cygthread.cc (cygthread::terminate): Clumsily detect when h has gone away and
attempt no further action.
2004-12-22 16:59:03 +00:00
Christopher Faylor 9c0d960d7f * cygthread.h (cygthread::release): Just declare here.
* cygthread.cc (cygthread::release): Define here.  Use InterlockedExchange to
set inuse or suffer potential races.
(cygthread::terminate): Use release().
2004-12-22 16:19:27 +00:00
Corinna Vinschen 4b84574c07 * fhandler_process.cpp (format_process_status): Use tabs in formatting
instead of spaces.
2004-12-22 11:35:29 +00:00
Corinna Vinschen 13d991bbea * path.cc (set_normalized_path): Allow empty pathnames. 2004-12-22 11:31:30 +00:00
Christopher Faylor e85c18a883 * spawn.cc (spawn_guts): Force parent to forget about P_DETACH'ed process. 2004-12-21 18:45:01 +00:00
Christopher Faylor e0520ec4b7 * path.cc (normalize_win32_path): Remove unneeded check for dots. 2004-12-20 17:55:22 +00:00
Christopher Faylor 8d060512a6 * path.cc (normalize_posix_path): Remove unneeded check for dots.
(path_conv::set_normalized_path): Strip trailing dots, similarly to what had
previously been done for the win32 path.
2004-12-20 16:31:18 +00:00
Danny Smith 7ffd6c6f17 * include/wchar.h (wcsdup): Correct prototype.
* include/string.h (wcsdup): Correct prototype.
2004-12-20 00:03:06 +00:00
Christopher Faylor b861c0a383 * path.cc (normalize_win32_path): Make third arg pass-by reference. Reorganize
slightly to eliminate extra variables.
(normalize_posix_path): Ditto.
(path_conv::check): Reflect change in arguments.
(mount_info::conv_to_posix_path): Ditto.
(mount_info::add_item): Ditto.
2004-12-19 03:27:09 +00:00
Christopher Faylor 5524af6e9b * child_info.h (CURR_CHILD_INFO_MAGIC): Use updated value.
* path.cc (path_conv::check): Check the output Win32 path for trailing spaces
and dots, not the input path.  Disallow all use of foo./bar since consistently
getting this right is time consuming.  Remove strange test for "unc\" since no
one seems to know what it's for.
2004-12-19 02:40:40 +00:00
Christopher Faylor bbe009b770 revert erroneous checkin 2004-12-18 16:41:27 +00:00
Christopher Faylor b25e8b65c2 * fhandler_proc.cc (proc_listing): Add entry for "self".
(proc_fhandlers): Add entry for "self".
* fhandler_process.cc (fhandler_process::fstate): Handle "self".
(fhandler_process::open): Handle "self".
2004-12-18 16:37:44 +00:00
Christopher Faylor 8232f2e050 * sigproc.cc (proc_subproc): Fix long-standing problem. Only wait for "all
processes" if pid == -1 -- not just if pid is negative.
(proc_can_be_signalled): Fix another long-standing problem.  Set correct errno
when detecting an exited process.
2004-12-17 17:42:03 +00:00
Corinna Vinschen a435749dc2 * fhandler_console.cc (get_win32_attr): Avoid inappropriate intensity
interchanging that used to render reverse output unreadable when
	non-reversed text is bright.
2004-12-16 13:19:08 +00:00
Corinna Vinschen 2ef89b220a * cygwin.din: Add utmpx symbols.
* syscalls.cc: Include utmpx.h.  Implement utmpx functions as stubs
	to utmp functions.
	(copy_ut_to_utx): New static function.
	(pututline): Change from void to struct utmp * as on Linux.
	(setutxent): New function.
	(endutxent): New function.
	(getutxent): New function.
	(getutxid): New function.
	(getutxline): New function.
	(pututxline): New function.
	* include/utmpx.h: New file.
	* include/cygwin/utmp.h: New file.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/utmp.h: Include cygwin/utmp.h.  Move stuff common with
	utmpx functionality there.
	(pututline): Declare struct utmp *.
2004-12-15 17:29:01 +00:00
Corinna Vinschen dad3ae73b3 * tty.cc (tty_list::terminate): Guard releasing the tty with tty_mutex.
(tty::init): Set master_pid to 0.
2004-12-14 17:19:22 +00:00
Corinna Vinschen 988566db0c * fhandler_console.cc (read): Consider offset within scrolling
region of the console window.
2004-12-14 12:09:51 +00:00
Corinna Vinschen c6ad91f3f8 * cygheap.h (cwdstuff::get_drive): Release cwd_lock. 2004-12-13 19:33:30 +00:00
Bas van Gompel 3020ba83ce * fhandler.cc (fhandler_base::puts_readahead): Fix end-condition. 2004-12-12 02:15:34 +00:00
Corinna Vinschen aee05403d1 * errno.cc (errmap): Map ERROR_INVALID_ADDRESS to EINVAL instead of
EOVERFLOW.
2004-12-10 17:43:00 +00:00
Christopher Faylor 804cd111b4 * include/sys/strace.h: Don't output paranoid_printf by default. 2004-12-10 16:25:35 +00:00
Christopher Faylor fc2eba361c * lib/libcmain.c (main): Properly deal with quoted first argument. 2004-12-09 21:28:32 +00:00
Danny Smith 8bbdc64198 * include/sqlext.h (SQL_INTERVAL_*): Correct macros.
Reported by Eric Sharkey <sharkey at netrics dot com>
2004-12-09 02:33:20 +00:00
Danny Smith 91ce86e773 * include/winnt.h (TOKEN_INFORMATION_CLASS): Add
TokenGroupsAndPrivileges, TokenSessionReference,
	TokenSandBoxInert, TokenAuditPolicy, TokenOrigin.
	Reformat.
	(SID_NAME_USE): Add SidTypeComputer.  Reformat.
	Thanks to Gabriel Linder <mingwlinder@users.sourceforge.net>
2004-12-07 07:15:26 +00:00
Christopher Faylor a8dead4476 * pinfo.h (proc_pipe::*): Delete class.
* pinfo.cc (proc_pipe::*): Ditto.
2004-12-06 19:20:24 +00:00
Christopher Faylor 8c43a9f82e * fork.cc (fork_parent): Reinstate "childhProc" protection. Don't close
hProcess handle here since it is used to ensure that a new process isn't
created with the old pid after the old pid exits.
* spawn.cc (spawn_guts): Ditto.
* pinfo.cc (proc_waiter): Don't send any signals if we've execed since this
process doesn't officially exist.
* pinfo.h (pinfo::pid_handle): Eliminate.  Just use hProc.
* sigproc.cc (sig_send): Don't send any signals if our sendsig doesn't exist.
That's a sign that we are execing.
(remove_proc): Eliminate pid_handle close.
2004-12-06 00:29:41 +00:00
Christopher Faylor 013f043fff fix typo 2004-12-05 21:39:47 +00:00
Christopher Faylor f181da2707 * cygthread.cc (cygthread::terminate_thread): Make public.
* pinfo.h (pinfo::wait_thread): New element.
* pinfo.cc (pinfo::wait): Store "handle" to started thread in pinfo.
* sigproc.cc (proc_terminate): Kill any threads waiting for a process pipe.
2004-12-05 21:29:37 +00:00
Christopher Faylor 54dd79bb44 * sigproc.cc (mychild): Reimplement as list scan.
(proc_subproc): Don't mess with pinfo if it's myself.
* child_info.h (child_info_types): Label enum for _PROC constants.
(child_info::child_info): New constructor.
(child_info::~child_info): New destructor.
(child_info::sync): Declare new function.
(child_info_fork::child_info_fork): New constructor.
(child_info_spawn::child_info_spawn): Remove old constructor.
(child_info_spawn::child_info_spawn): New constructor.
* dcrt0.cc (dll_crt0_0): Use correct sizeof when doing sanity check on passed
in child_info.  Signal readiness to parent when not forking (and not spawning).
* fork.cc (sync_with_child): Delete.
(resume_child): Remove extra argument.
(sync_with_parent): Use child_info method to sync with parent.
(fork_child): Don't close fork_info->subproc_ready since that is now handled by
the destructor.
(fork_parent): Remove subproc_ready stuff.  Use child_info sync method for
waiting..  Set start time here for child.  Rename "forked" to "child".
(fork): Check ch.subproc_ready for validity here.
* pinfo.h (_pinfo::exec_sendsig): Temp storage for exec stub which may be
staying around to handle non-cygwin captive process.
(_pinfo::exec_dwProcessId): Ditto.
(_pinfo::_lock): Renamed from lock.
(_pinfo::lock): New method.
(_pinfo::unlock): Ditto.
(_pinfo::initialize_lock): Ditto.
* pinfo.cc (set_myself): Use initialize_lock method to initialize myself lock.
Set "exec" fields in _pinfo to zero to indicate that we've started
successfully.  Set start time here when appropriate.
(_pinfo::commune_send): Use pinfo lock/unlock methods.
(proc_waiter): Remove special case for non-cywin processes.  Reinstitute
handling for PID_NOCLDSTOP.
* sigproc.cc (proc_subproc): Set proper EAGAIN errno when process table is
filled.
(sig_send): Use exec_* fields from _pinfo for sending signals if the the _pinfo
sendsig never materializes.
(child_info::child_info): New constructor, renamed from init_child_info.
Zeroes child_info structure and sets appropriate fields in structure based on
chtype.
(child_info::~child_info): New destructor.  Closes subproc_ready if it exists.
(child_info_fork::child_info_fork): New constructor.
(child_info_spawn::child_info_spawn): New constructor.
(child_info::ready): New function.  Signals parent when child is ready.
(child_info::sync): New function.  Wait for child to signal us or process to
die.
(remove_proc): Remove closing of hProcess since this should now be handled
shortly after process creation.
* spawn.cc (spawn_guts): Use child_info_spawn constructor rather than
init_child_info.  Save exec_sendsig and exec_dwProcessId in execing _pinfo.
Rely on child_info constructor to properly set parent_wr_proc_pipe in ciresrv.
Revert to previous determination on whether to start a process in suspended
mode.  Remove reparenting stuff.  Just keep a stub around if starting a
non-cygwin process.
2004-12-05 19:41:26 +00:00
Bas van Gompel d54b79d351 * fhandler.cc (fhandler_base::read): Remove superfluous check in
__small_printf format for strace.
2004-12-05 07:28:27 +00:00
Christopher Faylor 3a72ce9d12 minor cleanup 2004-12-05 02:30:20 +00:00
Bas van Gompel 8b6d072355 * fhandler.cc (fhandler_base::read): Don't debug_printf garbage when
copied_chars is zero.
2004-12-05 01:53:47 +00:00
Christopher Faylor e9efc27020 * environ.cc (environ_init): Alloc space for TERM if it is not set, like all of
the other environment variables.
2004-12-03 23:49:06 +00:00
Joshua Daniel Franklin b96fedfb8b 2004-12-02 Joshua Daniel Franklin <joshuadfranklin@yahoo.com>
* cygserver.sgml: Cleanup minor markup problem.
        * how-resources.texinfo: Add man and info to documentation FAQ
        * how-using.texinfo: Add more detail to Unicode FAQ.
        * install.texinfo: Finally apply Pierre's patch from 2003-03-03.
        * relnotes.texinfo: Add note about hyperthreading reports.
2004-12-03 05:30:52 +00:00
Christopher Faylor 82b7b4fd4f * child_info.h (child_info_fork::parent_wr_proc_pipe): New element.
* fork.cc (fork_parent): Set parent_wr_proc.
* pinfo.cc (set_myself): Close child_proc_info->parent_wr_proc if it exists
rather than trying to get value from parent _pinfo.
* pinfo.h (enum parent_aleter): New enum.
(pinfo::alert_parent): Declare as returning a value.
(pinfo::parent_alive): New function.
* pinfo.cc (pinfo::alert_parent): Set wr_proc_pipe to invalid non-NULL value
when parent disappears.  Return success of operation.
(proc_waiter): Use __ALERT_* enum for control since these are not really
signals.  Implement __ALERT_ALIVE.
* sigproc.cc (my_parent_is_alive): Eliminate.
* sigproc.h (my_parent_is_alive): Ditto for declaration.
(__SIGREPARENT): Eliminate.
2004-12-03 04:46:00 +00:00
Christopher Faylor 3ef7d75861 * pinfo.cc (pinfo::wait): Use better name for cygthread. 2004-12-03 02:49:54 +00:00
Pierre Humblet 8151e674ba 2004-12-03 Pierre Humblet <pierre.humblet@ieee.org>
* registry.h (reg_key::reg_key): Change arguments.
	* shared_info.h (class mount_info): Remove had_to_create_mount_areas.
	* registry.cc (reg_key::reg_key): Change constructors to always handle
	HKLM and to avoid relying on HKCU.
	Do not set mount_table->had_to_create_mount_areas.
	* path.cc (mount_info::conv_to_win32_path): Improve update of
	sys_mount_table_counter.
	(mount_info::read_mounts): Use new reg_key constructor.
	(mount_info::add_reg_mount): Ditto.
	(mount_info::del_reg_mount): Ditto.
	(mount_info::read_cygdrive_info_from_registry): Ditto.
	(mount_info::write_cygdrive_info_to_registry): Ditto.
	Update cygwin_shared->sys_mount_table_counter after registry update.
	(mount_info::get_cygdrive_info): Ditto.
	* shared.cc (shared_info::heap_chunk_size): Use new reg_key constructor.
	* environ.cc (regopt): Ditto.
2004-12-03 02:00:37 +00:00
Danny Smith f77390bbdb * lib/comctl32.def (ImageList_Copy, ImageList_DrawIndirect,
ImageList_Duplicate): Add stubs.
2004-12-02 05:55:45 +00:00
Danny Smith a923c24660 * lib/directx/strmiids.c (MEDIASUBTYPE_YV12): Correct GUID.
Thanks to "Pete" <pross@xvid.org>
2004-12-02 05:36:22 +00:00
Christopher Faylor ce71e000f1 * include/features.h: Include sys/cdefs.h, like linux. 2004-12-01 17:07:03 +00:00
Christopher Faylor ea9af94bd3 Add missing changelog entry. 2004-12-01 15:07:20 +00:00
Christopher Faylor 576bfeeca8 * syscalls.cc (truncate64): Don't second-guess errno if open fails. 2004-12-01 15:00:40 +00:00
Christopher Faylor 6903729981 * environ.cc (putenv): Accommodate recent newlib change in argument to putenv. 2004-11-26 04:21:47 +00:00
Christopher Faylor 8cb359d947 * child_info.h (child_info_spawn::hexec_proc): Eliminate.
* dcrt0.cc (dll_crt0_0): Remove hexec_proc stuff.
* fork.cc (fork_child): Remove call to pinfo_fixup_after_fork.
* pinfo.cc (set_myself): Close and zero pid_handle if set.
(pinfo_fixup_after_fork): Delete.
(proc_waiter): Don't close vchild.hProcess here.  Do that when we are remove
the vchild from procs.  Save hProcess as pid_handle only on first reparent
operation.
(pinfo::wait): Don't set pid_handle here.
(pinfo::alert_parent): Always try to send signal.  If unsuccessful then close
and zero wr_proc_pipe.
* pinfo.h (pinfo::pinfo): Make sure that appropriate parts of the class are
zeroed on construction.
(pinfo::alert_parent): Take char argument.
(pinfo_fixup_after_fork): Delete declaration.
(hexec_proc): Ditto.
* sigproc.cc (remove_proc): Close pid_handle and hProcess if appropriate.
* spawn.cc (spawn_guts): Set cygheap->pid_handle on first exec.
* cygheap.h (init_cygheap::pid_handle): New element.
* pinfo.cc (set_myself): Clear previously existing cygheap->pid_handle when a
new process has been started.
(pinfo::wait): Make sure that a handle to the newly forked/spawned process is
kept around so that the pid will not be reused.
* pinfo.h (_pinfo::pid_handle): Move.
(pinfo::pid_handle): to here.
* spawn.cc (spawn_guts): Create a pid_handle in cygheap prior to spawning to
ensure that the pid does not get reused during the lifetime of the "cygwin
pid".
* pinfo.h (pinfo::alert_parent): New function.
* exceptions.cc (sig_handle_tty_stop): Use alert_parent to send "signals" to
parent.
* fork.cc (fork_parent): Don't close pi.hProcess.  Let the waiter thread do
that.
* pinfo.cc (proc_waiter): Detect case where process exits without setting the
exit code and use value from GetExitCodeProcess.  Reluctantly implement
__SIGREPARENT.
(pinfo::alert_parent): Define.
* sigproc.h (__SIGREPARENT): New enum.
* spawn.cc (spawn_guts): Send reparent signal to parent on exec.  Always create
process in suspended state to avoid races.  Remove cygthread.h in favor of
cygtls.h throughout since cygtls now includes cygthread.h.  Eliminate
ppid_handle usage throughout.
* child_info.h: Regenerate magic number
(child_info): Remove pppid_handle.
* cygthread.h (cygthread::release): New method.  Frees thread without waiting.
* cygthread.cc (cygthread::stub): Set _ctinfo in _mytls to point to information
for executing thread.  Don't call SetEvent if thread is no longer in use.
(cygthread::simplestub): Ditto.
* cygtls.h (_cygtls::_ctinfo): New element contains pointer to information
about executing cygthread, if any.
* dcrt0.cc: Remove last vestiges of per_thread stuff.
(dll_crt0_0): Ditto.  Remove accommodation for ppid_handle.
(do_exit): Remove obsolete reparenting test.
(_exit): Exit with a more SUSv3-like exit value.
* dtable.cc (dtable::stdio_init): Check for myself->cygstarted rather than
myself->ppid_handle to see if we were started by a cygwin process.
* exceptions.cc (open_stackdumpfile): Ditto.
(handle_exceptions): Ditto.
(ctrl_c_handler): Ditto.
(sig_handle_tty_stop): Ditto.  Let parent send signal to itself on STOP.
(sigpacket::process): Comment out vfork test.
(signal_exit): Use more SUSv3-like exit value on signal.
* external.cc (fillout_pinfo): Don't set hProcess.
* fork.cc: Remove VFORK cruft.
(per_thread::set): Delete.
(fork_child): Remove perthread stuff.
(fork_parent): Remove obsolete subproc_init.  Accommodate new method for
tracking subprocesses.
* pinfo.cc (set_myself): Accommodate new pinfo/_pinfo layout.  Set some things
here that used to be set in wait_sig.
(_pinfo::exit): Set exitcode here.  Close process pipe.
(_pinfo::commune_send): Accommodeate new pinfo/_pinfo layout.
(proc_waiter): New function.  Waits, in a thread for subprocess to go away.
(pinfo::wait): New function.  Initialization for proc_waiter.
* pinfo.h (_pinfo::exitcode): New element.
(_pinfo::cygstarted): Ditto.
(_pinfo::wr_proc_pipe): Ditto.
(_pinfo::ppid_handle): Delete.
(_pinfo::hProcess): Delete.
(_pinfo::lock): Delete.
(pinfo::hProcess): New element.
(pinfo::lock): Ditto.
(pinfo::wait): Declare new function.
(pinfo::preserve): Define new function.
* sigproc.cc: Remove old stuff from wait_subproc thread based method.
(zombies): Remove.
(procs): New.
(my_parent_is_alive): Just check that the parent pid exists.
(mychild): Just use pinfo methods to determine if child is mine.
(proc_subproc): Revamp PROC_ADDCHILD to use pinfo::wait.  Remove
PROC_CHILDTERMINATED logic.  Use different method to remove processes from list
when SIGCHLD == SIG_IGN.
(proc_terminate): Gut.
(subproc_init): Delete.
(init_child_info): Remove setting of pppid_handle.
(checkstate): Revamp to only scan procs array.
(remove_proc): Rename from remove_zombie.  Don't close hProcess or pid_handle.
Don't release memory if it's myself.
(stopped_or_terminated): Change logic to handle new consolidated proc/zombie
array.
(wait_subproc): Delete.
* sigproc.h: Remove obsolete EXIT_* defines.
(subproc_init): Remove declaration.
* spawn.cc (spawn_guts): Remove reparenting stuff.  Use standard wait logic to
wait for child if started from a non-cygwin process.
* tlsoffsets.h: Regenerate.
* tty.cc (tty_init): Check for myself->cygstarted rather than
myself->ppid_handle to see if we were started by a cygwin process.
* include/sys/signal.h (external_pinfo::exitcode): Replace hProcess.
* include/sys/wait.h (WCOREDUMP): Define.
* fhandler_tty.cc (fhandler_tty_slave::read): Add debugging output for timeout
case.
* signal.cc (abort): Flag that we are exiting with the ABORT signal.
2004-11-26 04:15:10 +00:00
Christopher Faylor c6fdc68916 * select.cc (select_stuff::test_and_set): Remove extraneous tests of
"window_handle".
2004-11-22 15:38:17 +00:00
Danny Smith 7e33b8b32f 2004-11-21 Benoit Blanchon <bblanchon@users.sourceforge.net>
* include/wingdi.h (AC_SRC_ALPHA, AC_SRC_NO_ALPHA,
	AC_DST_NO_ALPHA, ...): Add defines.
	* include/winuser.h (ULW_COLORKEY,ULW_ALPHA,
	ULW_OPAQUE): Add defines.


	Change email address in ChangleLog to sourceforge alias
2004-11-21 23:55:55 +00:00
Danny Smith d11206f65b * include/winnt.h (VerSetConditionMask): Correct typo in _WIN32_WINNT
guard.
	* lib/kernel32.def (VerSetConditionMask): Correct stdcall
	suffix.
	* lib/ddk/ntoskrnl.def (VerSetConditionMask): Likewise.
2004-11-21 19:45:25 +00:00
Pierre Humblet 2d2a068087 2004-11-20 Pierre Humblet <pierre.humblet@ieee.org>
* fhandler.cc (fhandler::write): Remove debug_printf.
	* pipe.cc (fhandler_pipe::create): Edit syscall_printf format.
2004-11-20 23:42:36 +00:00
Pierre Humblet e70bea195b 2004-11-20 Pierre Humblet <pierre.humblet@ieee.org>
* cygheap.h (cygheap_user::get_windows_id): New method.
	* registry.h (get_registry_hive_path): Change argument type.
	(load_registry_hive): Ditto.
	* registry.cc (get_registry_hive_path): Change argument type and take
	Win9x keys into account.
	(load_registry_hive): Ditto.
	* uinfo.cc (cygheap_user::env_userprofile): Use get_windows_id, even
	for SYSTEM.
	* shared.cc (user_shared_initialize): Use get_windows_id.
	* syscalls.cc (seteuid32): Load the registry hive and reload the user
	shared also on Win9x.
2004-11-20 19:09:19 +00:00
Danny Smith 225699ae46 * include/winbase.h (PPROCESS_INFORMATION): Add typedef.
(CreateProcessWithLogonW): Declare.
	(LOGON_WITH_PROFILE, LOGON_NETCREDENTIALS_ONLY): Add defines.
	Thanks to: "jkmaki" <jkmaki@users.sourceforge.net>

	Correct some ChangeLog typos.
2004-11-20 00:03:08 +00:00
Danny Smith 78f717651f * include/sspi.h (SecPkgContext_Sizes): Fix typo.
Thanks to: David Leonard  <leonard@users,sourceforge.net>
2004-11-19 10:15:00 +00:00
Danny Smith 7fd30f5b15 * include/sspi.h (SecPkgCredentials_Names[AW]): Correct name.
Thanks to: David Leonard  <leonard@users,sourceforge.net>
2004-11-19 10:08:25 +00:00
Danny Smith 8f287205e8 2004-11-19 Magnus Olsen <greatlord@sourceforge.users.net>
* include/winuser.h (MSLLHOOKSTRUCT): Add structure.
2004-11-19 09:42:46 +00:00
Danny Smith 1e7e1a9fd7 2004-11-19 Magnus Olsen <greatlord@sourceforge.users.net>
* include/winuser.h (LLKHF_EXTENDED, LLKHF_INJECTED, LLKHF_UP):
	Add defines.
	(LLKHF_ALTDOWN): Define based on KF_ALTDOWN,
2004-11-19 09:35:09 +00:00
Danny Smith b359f9adfe 2004-11-19 Benoit Blanchon <benoit.blanchon@free.fr>
* include/shellapi.h (NIF_GUID): Add define.


Correct my 2004-11-04 Changelog entry
2004-11-19 08:30:26 +00:00
Earnie Boyd 3ff5506593 * include/w32api.h (Windows95, etc. and IE3, etc.): Add definitions. 2004-11-18 15:04:10 +00:00
Earnie Boyd 24984fcb45 2004-11-18 Earnie Boyd <earnie@users.sf.net>
* include/wincon.h (AttachConsole): Correct the _WIN32_WINNT filter.
	Changed it twice due to inconsistent MSDN documentation.
2004-11-18 13:57:06 +00:00
Earnie Boyd 43b9a723cc 2004-11-18 Earnie Boyd <earnie@users.sf.net>
* include/wincon.h (AttachConsole): Correct the _WIN32_WINNT filter.
2004-11-18 13:53:20 +00:00
Bas van Gompel d26eb2a13b * cygcheck.cc (eprintf): New function. 2004-11-18 05:20:23 +00:00
Bas van Gompel cd1ab47e38 * cygcheck.cc (find_on_path): Clear show_error and/or print_failed
parameters to display_error.
(rva_to_offset): Ditto.
(dll_info): Ditto.
(track_down): Ditto.
2004-11-16 05:16:59 +00:00
Pierre Humblet 87b838398a 2004-11-13 Pierre Humblet <pierre.humblet@ieee.org>
* kill.cc (forcekill): Do not pass negative pids to
	cygwin_internal. Check if sig == 0. Improve error messages.
	(main): Make pid a long long and distinguish between pids, gpids
	(i.e. negative pids) and Win9x pids.
2004-11-13 16:30:19 +00:00
Danny Smith 95e3512d53 * include/shlobj.h (SHGFP_TYPE): Add enum. 2004-11-13 10:36:08 +00:00
Danny Smith 6f68e4938c 2004-11-12 Lo�c Guilloux (glx@users.sourceforge.net>
* include/winuser.h (WM_THEMECHANGED): Add define.
2004-11-13 03:42:40 +00:00
Danny Smith d7dbb7f8d8 * include/ddk/winddk.h (ExAllocateFromPagedLookasideList,
ExFreeToPagedLookasideList): Guard inline versions with
	(__USE_NTOSKRNL__) && (_WIN32_WINNT >= 0x0501). Declare as
	external functions for earlier _WIN32_WINNT.
2004-11-12 08:26:44 +00:00
Christopher Faylor e8248d0132 * include/cygwin/version.h: Bump DLL minor number to 13. 2004-11-11 16:26:13 +00:00
Christopher Faylor 213c7a7d94 * cygcheck.cc: Change "keyeprint" to "display_error" throughout. 2004-11-11 01:56:02 +00:00
Christopher Faylor 28fbe53af8 * cygcheck.cc (main): Allow a '-l' without an additional argument. 2004-11-11 01:52:33 +00:00
Bas van Gompel 5ccf388ed8 * cygcheck.cc (keyeprint): New optional parameters: show_error and
print_failed.
2004-11-11 01:17:29 +00:00
Danny Smith eaec5f301f * include/ras.h (RASCONN[AW]): Remove dwSessionId field.
Fix typos in last ChangeLog entry
2004-11-10 20:05:01 +00:00
Danny Smith 9507f00e68 * include/winnls.h (WINBASEAPI): Define as DECLSPEC_IMPORT.
if  undefined. and __W32API_USE_DLLIMPORT__.
	Add WINBASEAPI token to prototypes, throughout.
2004-11-09 09:06:03 +00:00
Danny Smith 65fb2e4311 * include/winnt.h (GetCurrentFiber): Support -masm=intel.
(GetFiberData): Likewise.
	(NtCurrentTeb): Likewise.
2004-11-08 10:08:13 +00:00
Danny Smith c3ea0cd332 * include/wingdi.h (NIF_INFO): Add define.
(NIIF_*) Add defines..
	Thanks to: Benoit Blanchon <benoit.blanchon@free.fr>
	(NIF_*): Convert constants to hex.
2004-11-04 07:09:52 +00:00
Danny Smith 9dee1466e8 * include/wingdi.h (GetFontUnicodeRanges,GetGlyphIndicesA,
GetGlyphIndicesW): Declare.
	(GGI_MARK_NONEXISTING_GLYPHS): Define
	* lib/gdi32.def (GetFontUnicodeRanges,GetGlyphIndicesA,
	GetGlyphIndicesW): Add stubs.
2004-11-02 09:07:33 +00:00
Bas van Gompel fe5cd1608b * cygcheck.cc (get_dword): Fix errormessage.
(cygwin_info): Ditto.
(track_down): Ditto.
(check_keys): Ditto.
2004-10-31 18:46:31 +00:00
Christopher Faylor 22cf17b31f * fork.cc (NPIDS_HELD): Reduce to former number now that bash problem has been
identified.
2004-10-28 17:34:29 +00:00
Pierre Humblet 531979231d 2004-10-28 Pierre Humblet <pierre.humblet@ieee.org>
* path.cc (mount_info::from_registry): Deimpersonate while
        accessing HKLM.
        (mount_info::read_cygdrive_info_from_registry): Ditto.
        * cygheap.h: Define NO_IMPERSONATION.
        (cygheap_user::issetuid): Replace INVALID_HANDLE_VALUE by
        NO_IMPERSONATION.
        (cygheap_user::has_impersonation_tokens): Ditto.
        (cygheap_user::close_impersonation_tokens): Ditto.
        * uinfo.cc (uinfo_init): Ditto.
        * syscalls.cc (seteuid32): Ditto.
        * security.cc (set_impersonation_token): Ditto.
2004-10-28 01:46:01 +00:00
Bas van Gompel ccf4c1e6cd * cygcheck.cc (dump_sysinfo): Warn about missing or multiple cygwin1
dlls.
2004-10-27 01:28:07 +00:00
Christopher Faylor 5957d504f0 * cygtls.cc (_cygtls::fixup_after_fork): Wipe out exitsock local since it
should not be used by the child.
* select.cc (start_thread_socket): Turn off inheritance for exitsock.  Don't
add exitsock to exception mask since it should never get an exception.
(socket_cleanup): Change some debug messages for consistency.
* fhandler_socket.cc (fhandler_socket::dup): Change comment wording slightly.
2004-10-26 21:13:50 +00:00
Pierre Humblet fdf4ad73e1 2004-10-26 Pierre Humblet <pierre.humblet@ieee.org>
* registry.cc (get_registry_hive_path): Simplify and add a
        debug_printf in case of failure.
        (load_registry_hive): Revert the 2004-04-19 change.
2004-10-26 01:53:27 +00:00
Christopher Faylor 9a0fdd2315 whitespace 2004-10-25 21:20:09 +00:00
Bas van Gompel a3a401001a * cygcheck.cc (dump_sysinfo): Add leading newline before legend for
drive-list.
2004-10-25 16:11:41 +00:00
Christopher Faylor 4bfc614b42 fix whitespace, update some copyrights 2004-10-25 15:49:36 +00:00
Christopher Faylor bc4ab99276 Remove CRs 2004-10-25 15:35:41 +00:00
Danny Smith 244cbd6bda 2004-10-24 Dan Aloni <da-x@colinux.org>
* include/ddk/ntapi.h (NtQueryFullAttributesFile,
	ZwQueryFullAttributesFile): Declare.
	* include/ddk/ntapi.h (RtlDosPathNameToNtPathName_U):
	Declare.
	lib/ntoskrnl.def (ZwQueryDirectoryFile, ZwQueryFullAttributesFile.
	ZwQueryVolumeInformationFile): Add stubs.
2004-10-24 09:03:30 +00:00
Bas van Gompel be1d479e09 * cygcheck.cc (dump_sysinfo): In legend for drive-list: Add ``ram'' and
``unk''. Use single puts. Add leading newline. Line up equal-signs.
2004-10-22 01:29:10 +00:00
Christopher Faylor be957eb563 * cygcheck.cc (dump_sysinfo): Allow for larger drives in drive-list. Change
``Used'' to ``Free'' in helptext-title for drive-list.
2004-10-21 00:06:37 +00:00
Christopher Faylor 4082a9eb4a * select.cc (start_thread_socket): Remove attempt to delay reading of exitsock
or suffer occasional mysterious 60 second hangs.
(socket_cleanup): Empty the exitsock here after the thread has terminated.
2004-10-20 04:49:34 +00:00
Christopher Faylor d134b48fd6 revert erroneous checkin 2004-10-20 01:03:55 +00:00
Christopher Faylor f054a20f1a * fhandler_console.cc (fhandler_console::fixup_after_exec): Fix error message. 2004-10-20 01:02:18 +00:00
Corinna Vinschen 52fa622ab6 * sysv_sem.cc: Redefine offsetof to circumvent build problems with
gcc 3.4.
2004-10-18 14:26:18 +00:00
Corinna Vinschen eedf24742c * cygcheck.cc (pretty_id): Don't let i become negative. Fix
printf-format.
2004-10-18 10:25:38 +00:00
Danny Smith b64293e62a = include/wsahelp.h (WINSOCK_MAPPING, WSHGetWinsockMapping,
PWSH_GET_WINSOCK_MAPPING): Don't define if __OBJC__.
2004-10-18 04:31:16 +00:00
Christopher Faylor 3f8c5ee627 fix date 2004-10-18 01:47:00 +00:00
Christopher Faylor 0ffa77a9f5 * cygcheck.cc (pretty_id): Allocate space for ')' in uid and guid. 2004-10-18 01:44:55 +00:00
Christopher Faylor 0597641a74 * cygcheck.cc (pretty_id): Allocate space for trailing '\0' on uid and guid. 2004-10-17 23:31:23 +00:00
Christopher Faylor 167f0d8513 * cygcheck.cc (pretty_id): Don't exit on id error. Fix size calculations. 2004-10-15 13:57:56 +00:00
Danny Smith 12a638f990 2004-10-15 Robert Wruck <wruck@tweerlei.de>
Danny Smith  <dannysmith@users.sourceforge.net>

	= include/winbase.h (InitializeSListHead, Interlocked*):
	Guard with !__USE_NTOSKRNL__.

	* include/ddk/ntddk.h (__USE_NTOSKRNL__): Define.
	* include/ddk/winddk.h (InitializeSListHead, Interlocked*):
	Guard with  __USE_NTOSKRNL__.
	(ExInterlockedPopEntrySList, ExInterlockedPushEntrySList):
	Add prototypes.  Guard macro definition with __USE_NTOSKRNL__
	&& _WIN32_WINNT >= 0x0501
	(ExAllocateFromNPagedLookasideList, ExAllocateFromPagedLookasideList,
	ExFreeToNPagedLookasideList, ExFreeToPagedLookasideList):
	Replace calts to InterlockedPopEntrySList, InterlockedPushEntrySList
	with ExInterlockedPopEntrySList, ExInterlockedPushEntrySList.

	* lib/ddk/ntosknl.def (ExInterlockedPopEntrySList,
	ExInterlockedPushEntrySList)  Add stubs with fastcall decoration.
	(ExDesktopObjectType, ExEventObjectType, ExSemaphoreObjectType,
	ExWindowStationObjectType, IoAdapterObjectType,
	IoDeviceHandlerObjectSize, IoDeviceHandlerObjectType,
	IoDeviceObjectType, IoDriverObjectType, IoFileObjectType,
	LpcPortObjectType, MmSectionObjectType, SeTokenObjectType):
	Uncomment stubs.
2004-10-15 01:18:11 +00:00
Christopher Faylor 902edd4512 * cygcheck.cc (pretty_id): Correct column calculations. Abort if id is acting
funny.
2004-10-14 17:35:46 +00:00
Danny Smith 2457f34144 * include/sys/stat.h: Make S_ISLNK comment comply with ISO C90. 2004-10-14 07:44:11 +00:00
Christopher Faylor 96536b50a6 * select.cc (start_thread_socket): Remove unused code. 2004-10-13 03:26:31 +00:00
Christopher Faylor cbec131f8e * fhandler_termios.cc (fhandler_termios::tcsetpgrp): Revert previous checkin. 2004-10-11 15:36:13 +00:00
Danny Smith 77cbeb0039 2004-10-11 Robert Wruck <wruck@tweerlei.de>
* include/ddk/winddk.h (IoReleaseRemoveLockAndWait): Fix
        definition
        (IoReleaseRemoveLock): Add definition.
2004-10-11 07:20:26 +00:00
Christopher Faylor a82955fa29 minor change 2004-10-11 02:27:43 +00:00
Christopher Faylor 1cda132258 * cygtls.h (exitsock): New element.
(exitsock_sin): Ditto.
* cygtls.cc (_cygtls::init_thread): Initialize exitsock to invalid handle.
(_cygtls::call2): Close exitsock if it is valid.
* select.cc (struct socketinf): Remove sin element.
(start_thread_socket): Initialize one SOCK_DGRAM socket per thread instead of
(apparently) expensive opening and closing of socket with each select call.
(socket_cleanup): Send a byte to the exitsock socket as a way to potentially
signal a waiting-for-socket thread to exit.
* tlsoffsets.h: Regenerate.
2004-10-11 02:21:31 +00:00
Christopher Faylor 8d712c8c3e Remove unneeded directory. 2004-10-10 18:57:16 +00:00
Christopher Faylor 76ad4d0a6e * cygcheck.cc (add_path): Don't leak memory when path is already in ``paths''. 2004-10-10 17:07:23 +00:00
Danny Smith 7d032a010a * include/ddk/winnt4.h (Exi386InterlockedDecrementLong,
Exi386InterlockedExchangeUlong, Exi386InterlockedIncrementLong);
	Add prototypes.
	* include/winddk.h (ExInterlockedAddUlong,
	ExInterlockedInsertHeadList, ExInterlockedInsertTailList,
	ExInterlockedRemoveHeadList, ExInterlockedPopEntryList,
	ExInterlockedPushEntryList): Change calling convention to
	DDKAPI.
	(ExfInterlockedAddUlong,ExInterlockedInsertHeadList,
	ExInterlockedInsertTailList, ExInterlockedRemoveHeadList,
	ExInterlockedPopEntryList, ExInterlockedPushEntryList):
	Add prototypes for DDKFASTAPI versions.
	Thanks to Vadim Yegor0v <zg at bmg dot lv> for report.
	* lib/ntoskrnl.def (ExInterlockedAddUlong,
	ExInterlockedInsertHeadList, ExInterlockedInsertTailList,
	ExInterlockedRemoveHeadList, ExInterlockedPopEntryList,
	ExInterlockedPushEntryList): Remove lead '@' from stubs.
	(ExfInterlockedAddUlong,ExfInterlockedInsertHeadList,
	ExfInterlockedInsertTailList, ExfInterlockedRemoveHeadList,
	ExfInterlockedPopEntryList, ExfInterlockedPushEntryList):
	Add fastcall stubs.
	(Exi386InterlockedDecrementLong, Exi386InterlockedExchangeUlong,
	Exi386InterlockedIncrementLong); Add stdcall stubs.
2004-10-10 07:14:04 +00:00
Christopher Faylor 0795a24552 * cygcheck.cc (dump_sysinfo): Warn about trailing (back)slash on mount entries. 2004-10-09 23:19:38 +00:00
Christopher Faylor 82e127caac * cygcheck.cc (dump_sysinfo): Don't warn about empty path components, just
display ``.''.
2004-10-09 23:15:36 +00:00
Corinna Vinschen 60cb120f3e * cygheap.h (class cygheap_user): Add psystemroot member and
env_systemroot method.
	* environ.cc (struct spenv): Add add_always member.
	(spenvs): Accomodate new add_always member.  Add
	cygheap_user::env_systemroot method to SYSTEMROOT entry.
	(build_env): Check add_always member when adding missing environment
	variables from spenvs.
	* uinfo.cc (cygheap_user::env_systemroot): New method.
2004-10-07 21:28:57 +00:00
Corinna Vinschen 9286b55306 * dcrt0.cc (dll_crt0_0): Drop duplicated line. 2004-10-07 16:59:02 +00:00
Christopher Faylor d794d08157 revert erroneously applied change 2004-10-07 16:53:51 +00:00
Christopher Faylor 859d85dee0 * spawn.cc (pthread_cleanup::oldmask): Default to invalid signal mask.
(do_cleanup): Test for invalid signal mask to decide whether to restore the
mask rather than assuming zero mask indicates that there is nothing to do.
2004-10-07 16:49:30 +00:00
Corinna Vinschen b9cd8fb5ff * fhandler_tty.cc (fhandler_tty_slave::read): Use previously
evaluated time_to_wait value.
2004-10-07 08:03:24 +00:00
Danny Smith 72db1c11e9 * include/math.h (ashinh, asinhf, asinhl, acosh, acoshf, acoshl,
atanh, atanhf, atanhl): Add prototypes.
	* mingwex/Makefile.in (MATH_OBJS): Add objects for above to list.
	(MATH_DISTFILES): Add sources for above and fastmath.h to list.
	Specify dependency on fastmath.h for new objects.
	* mingwex/math/fastmath.h: New file.
	* mingwex/math/ashinh.c: New file.
	* mingwex/math/asinhf.c: New file.
	* mingwex/math/asinhl.c: New file.
	* mingwex/math/acosh.c: New file.
	* mingwex/math/acoshf.c: New file.
	* mingwex/math/acoshl.c: New file.
	* mingwex/math/atanh.c: New file.
	* mingwex/math/atanhf.c: New file.
	* mingwex/math/atanhl.c: New file.
2004-10-06 20:31:32 +00:00
Corinna Vinschen 4f8dc86255 * strace.cc (_impure_ptr): Remove. 2004-10-06 09:51:11 +00:00
Corinna Vinschen 5f175ea697 * cygcheck.cc (dump_sysinfo): Warn about empty path-components. 2004-10-06 09:46:40 +00:00
Pierre Humblet b0637a5191 2004-10-05 Pierre Humblet <pierre.humblet@ieee.org>
* external.cc (check_ntsec): Do not call wincap.has_security.
	* path.cc (path_conv::check): Ditto.
	* security.cc (get_object_attribute): Ditto.
	(get_file_attribute): Ditto.
2004-10-06 01:33:39 +00:00
Christopher Faylor 67eedd2473 revert erroneous checkin 2004-10-05 14:35:56 +00:00
Christopher Faylor 0190304668 * pinfo.cc (_pinfo::commune_send): Correct debugging output. 2004-10-05 02:10:15 +00:00
Corinna Vinschen 1f8b30497d * bsd_mutex.cc (_msleep): Simplify event creation. Revert change from
2004-08-24.  It should be unnecessary now.
	* msg.cc (client_request_msg::serve): Release process critical
	section as early as possible.
	* sem.cc (client_request_sem::serve): Ditto.
	* shm.cc (client_request_shm::serve): Ditto.
	* process.cc: Use hold and release method calls instead of
	EnterCriticalSection/LeaveCriticalSection calls throughout.
	* process.h (_hold): Rename from hold.  Take filename and linenumber
	parameter for logging.  Define matching hold macro.
	(release): Ditto.
2004-10-04 19:44:05 +00:00
Christopher Faylor 298cac75d5 fix erroneous checkin 2004-10-04 14:06:02 +00:00
Christopher Faylor 34421ac3e5 * include/cygwin/signal.h: Add siginterrupt definition. 2004-10-04 14:04:31 +00:00
Corinna Vinschen a5aa8c3e3a * cygcheck.cc (pretty_id): Close pipe. 2004-10-04 09:42:08 +00:00
Pierre Humblet e49bc789b2 2004-10-02 Pierre Humblet <pierre.humblet@ieee.org>
* path.h (enum path_types): Delete PATH_ISDISK.
	(path_conv::isdisk): Delete method.
	(path_conv::set_isdisk): Ditto.
	* path.cc (path_conv::check): Do not call set_isdisk.
	* uinfo.cc(pwdgrp::load): Do not call pc.isdisk.
2004-10-02 02:20:21 +00:00
Corinna Vinschen c6ef5fb7ec * sysv_sem.cc: Update to FreeBSD version 1.69.
1.68: Reduce the overhead of semop() by using the kernel stack
	instead of malloc'd memory to store the operations array if it
	is small enough to fit.
	1.69: Adjust the number of processes waiting on a semaphore properly
	if we're woken up in the middle of sleeping.
2004-10-01 11:18:10 +00:00
Joshua Daniel Franklin 00ee07cb12 * how-using.texinfo: Fix typo. Add note about "Install For All Users" 2004-09-30 19:58:07 +00:00
Danny Smith f49a3937c8 * include/winbase.h (WINBASEAPI): Define as DECLSPEC_IMPORT only
if __W32API_USE_DLLIMPORT__ is defined.
	* include/winuser.h (WINUSERAPI): Likewise.
2004-09-30 09:08:17 +00:00
Joshua Daniel Franklin 747d02f791 * how-using.texinfo: Add FAQ about network shares and authentication. 2004-09-30 05:19:27 +00:00
Joshua Daniel Franklin 5ee7c50819 2004-09-30 Joshua Daniel Franklin <joshuadfranklin@yahoo.com>
* how-programming.texinfo: Add gcj note to WinMain@16 FAQ.
	* how-using.texinfo: Add FAQ about network shares and authentication.
	* install.texinfo: Add "Where is make" to FAQ subtitle.
2004-09-30 05:03:52 +00:00
Danny Smith 85153fb164 2004-09-29 Filip Navara <xnavara@volny.cz>
* include/ddk/(atm.h, batclass.h, cfg.h, cfgmgr32.h, d4drvif.h,
	d4iface.h, ddkmapi.h, hidclass.h, hidpi.h, mcd.h, miniport.h,
	mountdev.h, mountmgr.h, ndis.h, ndistapi.h, ndiswan.h, netpnp.h,
	newdev.h, ntapi.h, ntdd8042.h, ntddbeep.h, ntddcdrm.h, ntddcdvd.h,
	ntddchgr.h, ntdddisk.h, ntddkbd.h, ntddmou.h, ntddpar.h, ntddpcm.h,
	ntddscsi.h, ntddser.h, ntddstor.h, ntddtape.h, ntddtdi.h,
	ntddvdeo.h, ntddvol.h, ntpoapi.h, parallel.h, pfhook.h, poclass.h,
	scsi.h, scsiscan.h, smbus.h, srb.h, storport.h, tdiinfo.h,
	tdikrnl.h, tvout.h, upssvc.h, usb.h, usb100.h, usbdi.h, usbioctl.h,
	usbiodef.h, usbscan.h, usbuser.h, videoagp.h, winddi.h, winddk.h,
	winnt4.h, ws2san.h): Fixed packing.
	* include/ddk/atm.h (ATM_TRAFFIC_DESCRIPTOR_IE): Fixed declaration.
	* include/ddk/hidclass.h (HID_INTERFACE_HIDPARSE,
	HID_INTERFACE_NOTIFY_PNP): Likewise.
	* include/ddk/ndis.h (NDIS_DMA_BLOCK, CO_FLOW_PARAMETERS): Likewise.
	(NdisQueryPacketLength): Added macro. Thanks to Art Yerkes
	<ayerkes@speakeasy.net>.
	* include/ddk/usb100.h (USB_CONFIGURATION_DESCRIPTOR): Fixed
	declaration.
	* include/ddk/winddi.h (PATHDATA, GLYPHPOS): Likewise.
	* include/ddk/winddk.h (PDRIVER_CONTROL, PDRIVER_LIST_CONTROL,
	PDRIVER_ADD_DEVICE, PIO_COMPLETION_ROUTINE, PDRIVER_CANCEL,
	PKDEFERRED_ROUTINE, PDRIVER_DISPATCH, PIO_DPC_ROUTINE,
	PMM_DLL_INITIALIZE, PMM_DLL_UNLOAD, PDRIVER_ENTRY,
	PDRIVER_INITIALIZE, PKSERVICE_ROUTINE, PIO_TIMER_ROUTINE,
	PDRIVER_REINITIALIZE, PDRIVER_STARTIO, PKSYNCHRONIZE_ROUTINE,
	PDRIVER_UNLOAD, DRIVER_OBJECT): Fixed callback declarations.
	(struct FILE_BASIC_INFORMATION): Renamed to _FILE_BASIC_INFORMATION.
	(SYNCH_LEVEL): Added definition.
	(KPCR, KPCR_TIB): Fixed declaration.
	(Interlocked[Push/Pop]EntrySList): Declare only if winbase.h isn't
	included and _WIN32_WINNT >= 0x0501.
	(RtlEqualLuid): Fixed macro definition.
	(KfLowerIrql, KfRaiseIrql): Declare and use instead of KeLowerIrql and
	KeRaiseIrql on i386 architectures.
2004-09-28 08:46:54 +00:00
Christopher Faylor e3e443e4df * fhandler_termios.cc (fhandler_termios::tcsetpgrp): Disallow attempts to set
the process group to a nonexistent process group.
2004-09-28 04:41:42 +00:00
Corinna Vinschen 2b94cfce89 * lib/_cygwin_crt0_common.cc: Revert patch from 2004-09-16. Brakes
newly built DLLs.
2004-09-27 16:30:44 +00:00
Christopher Faylor 98fc1a6dfe Sergey Ivanov <seriv@parkheights.dyndns.org>
* path.cc (mount_info::read_cygdrive_info_from_registry): Default /cygdrive to
binary mode.
2004-09-24 19:41:19 +00:00
Corinna Vinschen a638588d7c * cygwinenv.sgml: smbntsec is not on by default. 2004-09-24 09:47:10 +00:00
Corinna Vinschen e55ad3ece0 * sysv_shm.cc (kern_shmat): Avoid compiler warning. 2004-09-23 14:16:54 +00:00
Corinna Vinschen 79de498006 * dump_setup.cc (dump_setup): Remove unneeded strlen when check_files
is not set.
2004-09-23 10:32:20 +00:00
Pierre Humblet 20e474d7b8 2004-09-22 Pierre Humblet <pierre.humblet@ieee.org>
* path.cc (normalize_win32_path): Only look for : in second position.
	Avoid infinite loop with names starting in double dots.
	(mount_info::conv_to_win32_path): Do not worry about a trailing dot.
	(hash_path_name): Ditto.
2004-09-23 00:32:08 +00:00
Corinna Vinschen 71de401447 * dump_setup.cc (dump_setup): Avoid trailing spaces on package-list. 2004-09-22 11:50:51 +00:00
Corinna Vinschen 04e9ee5f15 * sysv_shm.cc (vm_object_reference): remove Cygwin specific define.
(vm_map_find): Ditto.
	(vm_map_inherit): Ditto.
	(kern_shmat): On Cygwin, take shmaddr just as is.  Don't call vm
	system calls on Cygwin.  Add comment.
2004-09-21 14:40:24 +00:00
Christopher Faylor 0ae97cf7dd * exceptions.cc (sig_handle_tty_stop): Set flag earlier. 2004-09-20 05:35:46 +00:00
Christopher Faylor ac652b501a . 2004-09-20 05:31:17 +00:00
Christopher Faylor e58412a2a0 * exceptions.cc (sig_handle_tty_stop): Set flag that we are in a cygwin
function to avoid a probably erroneous stack walk.
2004-09-20 04:58:36 +00:00
Corinna Vinschen af444ab7be * syscalls.cc (unlink): Don't use "delete on close" on remote shares. 2004-09-17 09:10:53 +00:00
Corinna Vinschen 95a12a8594 * cygwin.din (_impure_ptr): And export again. There are libs out there. 2004-09-17 08:34:31 +00:00
Corinna Vinschen 368ffbe3d8 * cygwin.din (_impure_ptr): Don't export.
(reent_data): Export.
	* lib/_cygwin_crt0_common.cc (_impure_ptr): Drop entirely.  Don't
	initialize _impure_ptr or u->impure_ptr_ptr.
2004-09-16 09:14:29 +00:00
Christopher Faylor 22a1a24f10 * cygwin.din (_impure_ptr): Export.
(reent_data): Don't export.
* dcrt0.cc (reent_data): Drop.
(__cygwin_user_data): Initialize impure_ptr as GLOBAL_REENT.
(_dll_crt0): Initialize _impure_ptr as GLOBAL_REENT.
* lib/_cygwin_crt0_common.cc (_impure_ptr): Drop.  Declare extern as dllimport
instead.
2004-09-16 03:49:03 +00:00
Corinna Vinschen 1dcd520bb8 Fix copyright throughout.
Eliminate use of _impure_ptr outside Cygwin.
	* bsd_helper.cc: Include errno.h instead of cygerrno.h.
	* bsd_mutex.cc : Ditto.
	* client.cc: Ditto.
	* cygserver.cc: Ditto.
	* process.cc: Don't build functions inside Cygwin.  Don't include
	cygerrno.h.  Don't set errno.
	* transport_pipes.cc (SET_ERRNO): New define.  Use througout.
	* transport_sockets.cc (SET_ERRNO): Ditto.
	(GET_ERRNO): Ditto.
2004-09-15 10:17:53 +00:00
Corinna Vinschen b103e0d732 * getfacl.c (main): Correct layout when nopt is set. 2004-09-15 07:51:06 +00:00
Christopher Faylor a9f36d288c * cygtls.h: Add alignment kludge to fix disparity between compilers.
* tlsoffsets.h: Regenerate.
* fork.cc (slow_pid_reuse): Use define to control number of pids held to
prevent pid reuse.
2004-09-14 23:44:50 +00:00
Christopher Faylor 272871abe4 * what.texinfo: Fix two typos reported on cygwin list. 2004-09-14 13:02:54 +00:00
Corinna Vinschen 599b41c4ec * autoload.cc (EnumProcessModules): Add.
* dlfcn.cc (dlsym): Handle RTLD_DEFAULT using EnumProcessModules().
	* include/dlfcn.h (RTLD_DEFAULT): Define to NULL.
2004-09-14 08:29:12 +00:00
Christopher Faylor fc3a42749f * fork.cc (slow_pid_reuse): Temporarily double the number of pids held to
prevent pid reuse.
2004-09-14 02:21:09 +00:00
Christopher Faylor de4e88a8df trivia change to force a new snapshot 2004-09-13 15:14:38 +00:00
Christopher Faylor a5eb75d60c * sigproc.cc (wait_sig): Ensure that waiting threads are awoken after returning
from a hold condition.
2004-09-12 19:34:08 +00:00
Christopher Faylor 3d65bb97e8 * child_info.h (CURR_CHILD_INFO_MAGIC): Update. 2004-09-12 18:10:15 +00:00
Christopher Faylor 013688df40 check in file missing from previous checkin. 2004-09-12 03:55:42 +00:00
Christopher Faylor d584454c82 * exceptions.cc: (ctrl_c_handler): Do nothing while a Cygwin subprocess is
starting.
* child_info.h (init_child_info): Remove pid argument from declaration.
* cygheap.h (init_cygheap::pid): New element.
* dcrt0.cc (dll_crt0_0): Eliminate handling of now-noexistent cygpid parameter
in child_info struct.  Set forkee to 'true' rather than cygpid since the pid
value was never used.
(dll_crt0_1): Ditto.
(_dll_crt0): Ditto.
* fork.cc (fork_child): Don't wait for sigthread.  This is handled in the fork
call now.
(fork_parent): Remove obsolete pid argument from init_child_info call.  Don't
do anything special with cygpid when DEBUGGING.
(fork): Delay all signals during fork.
(fork_init): Don't do anything special when DEBUGGING.
* pinfo.cc (set_myself): Remove pid parameter.  Use new pid field in cygheap.
(pinfo_init): Don't pass pid argument to set_myself.
* sigproc.cc (sig_send): Wait for dwProcessId to be non-zero as well as
sendsig.
(init_child_info): Eliminate handling of pid.
(wait_sig): Implement method to temporarily hold off sending signals.
* sigproc.h (__SIGHOLD): New enum.
(__SIGNOHOLD): Ditto.
* spawn.cc (spawn_guts): Remove obsolete pid argument from init_child_info
call.
2004-09-12 03:47:57 +00:00
Corinna Vinschen d495ee9ff0 * fhandler.cc (fhandler_base::dup): Use debug_printf. 2004-09-10 08:34:37 +00:00
Corinna Vinschen 4875a4b66e * Makefile.in: Create libutil.a from bsdlib.o exports.
* bsdlib.cc (logwtmp): Move from syscalls.cc to here.
	(login): Ditto.
	(logout): Ditto.

	* winsup.h (EXPORT_ALIAS): New macro.
	* exec.cc: Define alias symbols using EXPORT_ALIAS macro.
	* syscalls.cc: Ditto.
	* times.cc: Ditto.
2004-09-10 08:30:51 +00:00
Corinna Vinschen 1f97020ae6 * fhandler_tape.cc (fhandler_dev_tape::open): Fix typo. 2004-09-09 11:35:15 +00:00
Corinna Vinschen 6423296840 * pipe.cc (create_selectable_pipe): Work around bug in Windows 95
where CreateNamedPipe returns NULL.
2004-09-09 08:58:44 +00:00
Earnie Boyd bbb5869af9 * include/sys/stat.h (_S_IFLNK): Add definition.
(S_IFLNK) Ditto.
	(_lstat) Ditto.
	(lstat) Ditto.
	(_S_ISLNK) Recode.
	(S_ISLNK) Ditto.
2004-09-09 02:05:22 +00:00
Earnie Boyd 57ad1153a6 * include/sys/stat.h (_S_ISLNK): Add definition.
(S_ISLNG): Ditto.
2004-09-08 18:24:13 +00:00
Pierre Humblet a456320915 2004-09-05 Pierre Humblet <pierre.humblet@ieee.org>
* cygheap.h (cwdstuff::drive_length): New member.
        (cwdstuff::get_drive): New method.
        * path.cc (normalize_win32_path): Simplify by using cwdstuff::get_drive.
        (mount_info::conv_to_win32_path): Use cwdstuff::get_drive as default for /.
        (cwdstuff::set): Initialize drive_length.
2004-09-07 23:26:28 +00:00
Christopher Faylor 6f7a746cee * cygtls.cc (_cygtls::init_thread): Set __sdidinit to negative value to
indicate that it is "special".
* thread.cc (pthread::exit): If __sdidinit is < 0, it was never really
initialized so reset it to 0 before calling _reclaim_reent.
2004-09-07 04:05:14 +00:00
Corinna Vinschen ab21f18c95 * bsd_mutex.cc (_msleep): Disable resetting event object for now. 2004-09-06 20:32:45 +00:00
Danny Smith b2e7654908 2004-09-06 Hosaka Yuji <hos@tamanegi.org>
* include/mshtml.h (IHTMLDocument2): Correct get_selection
	declaration.
	(IHTMLSelectionObject): Correct get_type declaration.
	(IHTMLFramesCollection2, IHTMLWindow2, IHTMLFrameBase,
	IHTMLFrameBase2, IHTMLFrameBase3, IHTMLBodyElement,
	IHTMLBodyElement2): Add interfaces.
	(LPHTMLIMAGEELEMENTFACTORY, LPHTMLEVENTOBJ, LPHTMLSCREEN,
	LPHTMLOPTIONELEMENTFACTORY, LPOMHISTORY, LPOMNAVIGATOR): Add
	typedefs.
	* lib/mshtml-uuid.c (IID_IHTMLFrameBase2, IID_IHTMLFrameBase3):
	Add IIDs.
2004-09-06 09:09:33 +00:00
Christopher Faylor dda37cd219 * include/cygwin/version.h: Bump DLL minor number to 12. 2004-09-05 16:08:44 +00:00
Earnie Boyd b73441fc30 * include/w32api.h: Increment version to 3.1.
* Makefile.in: Ditto.
2004-09-05 15:27:56 +00:00
Earnie Boyd 71c68d9607 * mingwex/Makefile.in: Correct typo in list of DISTFILES. 2004-09-05 14:15:01 +00:00
Earnie Boyd 665352facd * include/_mingw.h: Increment minor version for 3.5 release.
* Makefile.in: Ditto.
2004-09-05 13:51:33 +00:00
Danny Smith 4f52488e06 2004-09-05 Hosaka Yuji <hos@tamanegi.org>
* include/winuser.h (MonitorFromPoint, MonitorFromRect,
	MonitorFromWindow): Add prototypes.
	* lib/user32.def (MonitorFromPoint, MonitorFromRect,
	MonitorFromWindowMonitorFromWindow): Add stubs.
	* include/shellapi.h (DuplicateIcon): Add prototype.
2004-09-05 10:35:34 +00:00
Danny Smith 99f91ded6c * include/winuser.h (WINUSERAPI): New define.
Use it to mark user32.dll imports, throughout.
2004-09-05 10:14:26 +00:00
Danny Smith e636a59f52 22004-09-05 Hosaka Yuji <hos@tamanegi.org>
* lib/ddk/hid.def (HidD_FlushQueue, HidD_FreePreparsedData,
	HidD_GetAttributes, HidD_GetConfiguration, HidD_GetFeature,
	HidD_GetHidGuid, HidD_GetIndexedString, HidD_GetInputReport,
	HidD_GetManufacturerString, HidD_GetMsGenreDescriptor,
	HidD_GetNumInputBuffers, HidD_GetPhysicalDescriptor,
	HidD_GetPreparsedData, HidD_GetProductString,
	HidD_GetSerialNumberString, HidD_SetConfiguration,
	HidD_SetFeature, HidD_SetNumInputBuffers, HidD_SetOutputReport,
	HidP_GetButtonCaps, HidP_GetValueCaps): Add exports.
2004-09-05 10:05:24 +00:00
Corinna Vinschen eea5dd9707 * security.cc: Fix a few more strace_prints. 2004-09-03 08:18:41 +00:00
Christopher Faylor 0cd9f74fa5 Regularize most strace_prints throughout so that %E is always preceded by a
comma and elminate most uses of "foo = %s" to "foo %s".
2004-09-03 01:53:12 +00:00
Christopher Faylor 6644c628f5 Christopher Faylor <cgf@timesys.com>
* autoload.cc (NtQueryInformationFile): Return nonzero on error.
* ntdll.h (FILE_PIPE_LOCAL_INFORMATION): Add.
(NtQueryInformationFile): Fix types for last two arguments.
* pipe.cc: Include stdlib.h, limits.h, and ntdll.h.
(create_selectable_pipe): New function to create a pipe that can be used with
NtQueryInformationFile for select.
(fhandler_pipe::create): Call create_selectable_pipe instead of CreatePipe.
(pipe): Use DEFAULT_PIPEBUFSIZE as argument to create_pipe.
* select.cc: Include limits.h and ntdll.h.
(peek_pipe): Add select_printf output.  Call NtQueryInformationFile to
implement select for write on pipes.
(fhandler_pipe::select_read): Reorder field assignments to be consistent with
fhandler_pipe::select_write.
(fhandler_pipe::select_write): Initialize startup, verify, cleanup, and
write_ready fields for select_record.
(fhandler_pipe::select_except): Tweak indentation to be consistent with
fhandler_pipe::select_write.
2004-09-03 01:32:02 +00:00
Corinna Vinschen 79eebb79a6 * textbinary.sgml: Change default mode for non-mounted paths to binary. 2004-09-02 08:14:49 +00:00
Corinna Vinschen f0720ce7cb * sysv_shm.cc (kern_shmat): Add debug_printf's. 2004-08-31 10:47:27 +00:00
Christopher Faylor 72067ccafa * fork.cc (fork_parent): Return the cygpid directly derived from the winpid. 2004-08-31 03:34:04 +00:00
Christopher Faylor 1af912ce3c * fork.cc (fork_parent): Record child's pid when we're sure that it has been
filled out by the child.
* pinfo.cc (pinfo::init): Trivial change.
2004-08-30 22:08:50 +00:00
Corinna Vinschen c01edcda76 * fhandler_disk_file.cc (fhandler_disk_file::fchmod): Allow to report
success on systems with ntsec and ntea set.
2004-08-29 09:32:49 +00:00
Corinna Vinschen ddea76a66b * fhandler.cc (fhandler_base::write): In the lseek_bug case, set EOF
before zero filling. Combine similar error handling statements.
2004-08-28 15:46:57 +00:00
Pierre Humblet 2e41976b56 2004-08-28 Pierre Humblet <pierre.humblet@ieee.org>
* syscalls.cc (ftruncate64): On 9x, call write with a zero length
        to zero fill when the file is extended.
2004-08-28 01:37:27 +00:00
Danny Smith b8a6a751f4 2004-08-25 Lars Rune N�stdal <daysleper@users.sourceforge.net>
* include/wincon.h (CONSOLE_FULLSCREEN_MODE, CONSOLE_WINDOWED_MODE):
	Add defines.
	(PCOORD): Add typedef.
	(GetConsoleDisplayMode, SetConsoleDisplayMode): Add prototypes.
2004-08-25 08:43:25 +00:00
Danny Smith 6f564c4f6e * include/winldap.h: Don't check value of UNICODE.
Thanks to: "Jean-Do"  <spab@users.sourceforge.net>
2004-08-25 07:55:59 +00:00
Danny Smith 72fdc157bf * include/winbase.h (WINBASEAPI): Guard with __INSIDE_CYGWIN__. 2004-08-24 23:20:42 +00:00
Corinna Vinschen bb647ab68c * syscalls.cc (link): Avoid compiler warning. 2004-08-24 22:49:16 +00:00
Corinna Vinschen 1532dd53a5 * bsd_mutex.cc (_msleep): Release process object while waiting. 2004-08-24 22:04:18 +00:00
Corinna Vinschen 26657d6052 * winsup.api/mmaptest01.c (main): Accomodate 9x memory usage. 2004-08-24 09:58:16 +00:00
Corinna Vinschen 327284cf3a * winsup.api/ltp/symlink01.c (do_link): Print inode numbers using %llu
format specifier.
2004-08-24 09:34:04 +00:00
Danny Smith d5afcd86f9 * include/malloc.h (__mingw_aligned_offset_malloc,
__mingw_aligned_offset_realloc, __mingw_aligned_malloc,
	__mingw_aligned_realloc, __mingw_aligned_free): Add
	prototypes.
	* mingwex/Makefile.in (DISTFILES): Add mingw-aligned-malloc.c,
	tst-aligned-malloc.c.
	(REPLACE_OBJS): Add mingw-aligned-malloc.o.
2004-08-24 09:02:45 +00:00
Danny Smith a6c2ea7e7c 2004-08-24 Steven G. Johnson <stevenj@alum.mit.edu>
* mingwex/mingw-aligned-malloc.c: New file.
	* mingwex/tst-aligned-malloc.c: New file.
2004-08-24 08:55:42 +00:00
Danny Smith 45b1139e41 * crt1.c: (__mingw_CRTStartup): Change return to void. Add
noreturn attribute. Align stack to 16 bytes before passing args
	to main.
	(mainCRTStartup): Change return to void.
	(WinMainCRTStartup): Likewise.
2004-08-24 08:49:33 +00:00
Danny Smith 4cb4a4710a 2004-08-24 Sam Robb <samrobb@users.sourceforge.net>
* include/winbase.h (GetFileSizeEx): Add _WIN32_WINNT >= 0x0500
	guard.
2004-08-23 22:01:57 +00:00
Danny Smith ace32bda79 * include/winbase.h: Add WINBASEAPI token to prototypes, throughout. 2004-08-23 21:56:11 +00:00
Corinna Vinschen 12618f5ff5 * environ.cc (set_ntea): New function.
(set_ntsec): Ditto.
	(set_smbntsec): Ditto.
	(parse_thing): Change ntea, ntsec and smbntsec settings to call
	appropriate functions.
2004-08-21 15:50:33 +00:00
Corinna Vinschen 7c48171279 * fhandler_tape.cc (fhandler_dev_tape::raw_read): Use ?: instead of
if/else.
	(fhandler_dev_tape::raw_write): Return -1 in case of error.
2004-08-20 13:40:35 +00:00
Corinna Vinschen b9188d6c1e * errno.cc (_sys_errlist): Change various text to their english Linux
counterparts.  Unify layout.
	(strerror): Remove switch statement.
2004-08-19 18:26:58 +00:00
Corinna Vinschen 8cb783ba56 * fhandler.cc (fhandler_base::open): Set shared flags to 0 when
opening a tape device.
2004-08-19 15:47:51 +00:00
Corinna Vinschen f0eeb667b8 * ChangeLog: Fix typo. 2004-08-19 15:31:53 +00:00
Corinna Vinschen 82b3018088 * fhandler_socket.cc (fhandler_socket::dup): Decrement dtable's
need_fixup_before counter on successful dup.
	* net.cc (cygwin_getpeername): Add file descriptor to debug output.
2004-08-19 10:58:37 +00:00
Corinna Vinschen 8f663bd642 * fhandler.h (fhandler_dev_dsp:~fhandler_dev_dsp): Delete.
(fhandler_dev_dsp::open_count): Delete.
	(fhandler_dev_dsp::close_audio_in): New method declaration.
	(fhandler_dev_dsp::close_audio_in): Ditto.
	* fhandler_dsp.cc: Add and edit debug_printf throughout.
	(fhandler_dev_dsp::Audio::denyAccess): Delete.
	(fhandler_dev_dsp::Audio::fork_fixup): Ditto.
	(fhandler_dev_dsp::Audio::getOwner): Ditto.
	(fhandler_dev_dsp::Audio::clearOwner): Ditto.
	(fhandler_dev_dsp::Audio::owner_): Ditto.
	(fhandler_dev_dsp::Audio::setformat): Ditto, rename to setconvert.
	(fhandler_dev_dsp::Audio::lock): Ditto, move to queue.
	(fhandler_dev_dsp::Audio::unlock): Ditto.
	(fhandler_dev_dsp::Audio::lock_): Ditto.
	(fhandler_dev_dsp::Audio::bufferIndex_): New member, from Audio_out
	and Audio_in.
	(fhandler_dev_dsp::Audio::pHdr_): Ditto.
	(fhandler_dev_dsp::Audio::wavehdr_): Ditto.
	(fhandler_dev_dsp::Audio::bigwavebuffer_): ditto.
	(fhandler_dev_dsp::Audio::Qisr2app_): Ditto.
	(fhandler_dev_dsp::Audio::setconvert): New method, from old setformat.
	(fhandler_dev_dsp::Audio::queue::lock): New method.
	(fhandler_dev_dsp::Audio::queue::unlock): Ditto.
	(fhandler_dev_dsp::Audio::queue::dellock): Ditto.
	(fhandler_dev_dsp::Audio::queue::isvalid): Ditto.
	(fhandler_dev_dsp::Audio::queue::lock_): New member.
	(fhandler_dev_dsp::Audio::queue::depth1_): Delete.
	(fhandler_dev_dsp::Audio_out::fork_fixup): New method.
	(fhandler_dev_dsp::Audio_out::isvalid): New method.
	(fhandler_dev_dsp::Audio_out::start): Remove arguments.
	(fhandler_dev_dsp::Audio_out::parsewav): Change arguments and set
	internal state.
	(fhandler_dev_dsp::Audio_out::emptyblocks): Delete.
	(fhandler_dev_dsp::Audio_out::Qapp2app_): Ditto.
	(fhandler_dev_dsp::Audio_out::Qisr2app_): Ditto, move to Audio.
	(fhandler_dev_dsp::Audio_out::bufferIndex_): Ditto.
	(fhandler_dev_dsp::Audio_out::pHdr_): Ditto.
	(fhandler_dev_dsp::Audio_out::wavehdr_): Ditto.
	(fhandler_dev_dsp::Audio_out::bigwavefuffer_): Ditto.
	(fhandler_dev_dsp::Audio_out::freq_): New member.
	(fhandler_dev_dsp::Audio_out::bits_): New member.
	(fhandler_dev_dsp::Audio_out::channels_): New member.
	(fhandler_dev_dsp::Audio_in::fork_fixup): New method.
	(fhandler_dev_dsp::Audio_in::isvalid): New method.
	(fhandler_dev_dsp::Audio_in::Qapp2app_): Delete.
	(fhandler_dev_dsp::Audio_in::Qisr2app_): Ditto, move to Audio.
	(fhandler_dev_dsp::Audio_in::bufferIndex_): Ditto.
	(fhandler_dev_dsp::Audio_in::pHdr_): Ditto.
	(fhandler_dev_dsp::Audio_in::wavehdr_): Ditto.
	(fhandler_dev_dsp::Audio_in::bigwavefuffer_): Ditto.
	(fhandler_dev_dsp::Audio::queue::queue): Simplify.
	(fhandler_dev_dsp::Audio::queue::send): Use lock.
	(fhandler_dev_dsp::Audio::queue::query): Do not use depth1_.
	(fhandler_dev_dsp::Audio::queue::recv): Ditto.
	(fhandler_dev_dsp::Audio::Audio): Adapt to new class members.
	(fhandler_dev_dsp::Audio::~Audio): Ditto
	(fhandler_dev_dsp::Audio_out::start): Reorganize.
	(fhandler_dev_dsp::Audio_out::stop): Simplify.
	(fhandler_dev_dsp::Audio_out::init): Reset the queue and clear flag.
	(fhandler_dev_dsp::Audio_out::write): Reorganize to allocate audio_out.
	(fhandler_dev_dsp::Audio_out::buf_info): Use appropriate block size.
	(fhandler_dev_dsp::Audio_out::callback_sampledone): Do not use lock.
	(fhandler_dev_dsp::Audio_out::waitforspace): Simplify.
	(fhandler_dev_dsp::Audio_out::waitforallsent):Ditto.
	(fhandler_dev_dsp::Audio_out::sendcurrent): Reorganize.
	Clear flag before requeuing.
	(fhandler_dev_dsp::Audio_out::parsewav):
	(fhandler_dev_dsp::Audio_in::start): Reorganize.
	(fhandler_dev_dsp::Audio_in::stop): Simplify.
	(fhandler_dev_dsp::Audio_in::queueblock): Ditto.
	Requeue header in case of error.
	(fhandler_dev_dsp::Audio_in::init): Reset the queue and clear flag.
	(fhandler_dev_dsp::Audio_in::waitfordata): Simplify.
	Do not UnprepareHeader if the flag is zero.
	(fhandler_dev_dsp::Audio_in::buf_info): Ditto.
	(fhandler_dev_dsp::Audio_in::callback_blockfull): Do not use lock.
	(fhandler_dev_dsp::open_count): Delete.
	(fhandler_dev_dsp::open): Only check existence, do not allocate
	anything. Set flags appropriately. Create archetype.
	(fhandler_dev_dsp::write): Call archetype as needed. Create audio_out.
	(fhandler_dev_dsp::read): Call archetype as needed. Create audio_in.
	(fhandler_dev_dsp::close): Call archetype as needed.
	Call close_audio_in and close_audio_out.
	(fhandler_dev_dsp::close_audio_in): New function.
	(fhandler_dev_dsp::close_audio_out): New function.
	(fhandler_dev_dsp::dup): Use archetypes.
	(fhandler_dev_dsp::ioctl): Call archetype as needed. Reorganize for
	new structures.
	(fhandler_dev_dsp::fixup_after_fork): Call archetype as needed.
	(fhandler_dev_dsp::fixup_after_exec): Call archetype as needed.
	Clear audio_in and audio_out.
2004-08-17 09:52:50 +00:00
Corinna Vinschen 86b652f9c8 * devdsp.c: Outputs the names of the main test functions.
(forkrectest): Expect child success.
	(forkplaytest): Ditto.
	(syncwithchild): Output the child status and the desired value.
	(sinegenw): Reduce volume of the beep.
	(sinegenb): Ditto.
	(dup_test): New test.
2004-08-17 09:51:31 +00:00
Danny Smith 6e8285f48b * profile/COPYING: New file.
* profile/CYGWIN_LICENSE: New file.
	* profile/Makefile.in (DISTFILES): Add COPYING, CYGWIN_LICENSE.
2004-08-15 11:35:07 +00:00
Danny Smith 48a27980be * mingwex/fopen64.c: Move.
* mingwex/fseeko64.c: Move.
        * mingwex/ftello64.c: Move.
        * mingwex/lseek64.c: Move.
        * mingwex/stdio/fopen64.c: To here.
        * mingwex/stdio/fseeko64.c: To here.
        * mingwex/stdio/ftello64.c: To here.
        * mingwex/stdio/lseek64.c: To here.

	White space cleanup in ChangeLog
2004-08-15 11:28:09 +00:00
Danny Smith 40929746ba * profile/gmon.c [__MINGW32__]: Include string.h for
memset prototype.
2004-08-15 10:45:43 +00:00
Danny Smith 18cff5fa2b 2004-08-15 Ken Fitlike <kenfitlike@users.sourceforge.net>
* include/commctrl.h (WC_TREEVIEWA): Remove parenthenses.
2004-08-15 08:51:20 +00:00
Pierre Humblet 252dd88138 2004-08-14 Pierre Humblet <pierre.humblet@ieee.org>
* fhandler.cc (fhandler_base::open_9x): Set file attributes
	for new files.
2004-08-14 03:01:21 +00:00
Christopher Faylor cb3f750c79 * net.cc (cygwin_gethostbyname): Show failing host name on error. 2004-08-11 18:34:32 +00:00
Danny Smith d1a40176a4 2004-08-10 Sebastian Nowak <snowak1@users.sourceforge.net>
* include/ws2spi.h (LPWSPSELECT): Correct typedef.
2004-08-11 08:10:22 +00:00
Danny Smith c31c2194f3 * include/wincrypt.h: Correct _WIN32_WINNT typo. 2004-08-11 07:51:56 +00:00
Danny Smith dbe6474a4a 2004-08-10 Ed Schaller <schallee@darkmist.net>
* include/wincrypt.h (MS_ENH_RSA_AES_PROV_A, MS_ENH_RSA_AES_PROV_W)
	(ALG_SID_AES_128, ALG_SID_AES_192, ALG_SID_AES_256, ALG_SID_AES 17)
	(CALG_AES_128, CALG_AES_192, CALG_AES_256, CALG_AES,PROV_RSA_AES):
	Add defines.
	(CALG_SHA1): Add define.
	(HP_HMAC_INFO): Add define.
	(HMAC_INFO): Add struct.
	(BLOBHEADER): Add typedef.
2004-08-11 07:42:57 +00:00
Christopher Faylor 34b14e0b26 white space 2004-08-10 15:18:36 +00:00
Christopher Faylor fe3db6cc89 * select.cc (select_stuff::wait): Correctly check for w4 array bounds. 2004-08-10 15:05:37 +00:00
Christopher Faylor 3f604cbca4 * mingwex/stdio/vwscanf.c: Add stdio.h needed after 2004-08-07 change. 2004-08-09 01:17:28 +00:00
Danny Smith ac8cbf3d2d * include/complex.h: Remove __attribute__ ((const)) from
transcendantal and trig functions.  Replace __attribute__ ((const))
	with __MINGW_ATTRIB_CONST on other declarations.
2004-08-07 07:58:01 +00:00
Danny Smith 889a573ad8 * include/wchar.h: Reorganize, avoid including other headers. 2004-08-07 07:51:14 +00:00
Danny Smith a794235489 * include/string.h (memchr, memcmp, strchr, strcmp, strcspn)
(strlen, strncmp, strpbrk, strrchr, strspn, strstr): Add pure
        attribute.
2004-08-06 21:49:54 +00:00
Corinna Vinschen 3410b5be3e * errno.cc (errmap): Add ERROR_TOO_MANY_LINKS -> EMLINK mapping.
* syscalls.cc (link): Only copy files if FS doesn't support hard links.
2004-08-03 14:37:26 +00:00
Corinna Vinschen 8c97671600 * transport.cc (transport_layer_base::~transport_layer_base): Resurrect.
* transport.h (transport_layer_base::~transport_layer_base): Ditto.
2004-08-03 12:35:35 +00:00
Corinna Vinschen a918549275 * bsd_mutex.cc (_msleep): Reset event object and close it before
entering mutex.  Turn order of conditional for better readability.
2004-07-30 14:48:19 +00:00
Danny Smith 8b7083824a * include/dirent.h (struct _wdirent): Remove obsolete comment. 2004-07-30 08:27:29 +00:00
Danny Smith 57cb31d40c * include/string.h: Revert 2004-07-26 additions of
__ATTRIBUTE_PURE.
2004-07-30 08:19:58 +00:00
Danny Smith ab8cc34bb7 * mingwex/math/powl.c (powl): Revert change of 2004-02-01.
(__convert_inf_to_maxnum): New.static inline.
	(reducl): Use it to protect against Inf - Inf.
	(__fast_ldexpl): New function.  Use in lieu of ldexpl.
2004-07-28 11:25:27 +00:00
Danny Smith 5ea3a6e152 * mingwex/math/expl.c (expl): Move body of code to new static
function __expl, removing tests for +/-Inf. Extern function
	expl calls __expl after testing for max, min log thresholds.
2004-07-27 08:03:36 +00:00
Danny Smith 1856fdbe03 * mingwex/stdio/vsscanf.c: Add "edi" to registers-modified field
* mingwex/stdio/vfscanf.c: Likewise.
	* mingwex/stdio/vswscanf.c: Likewise.
	* mingwex/stdio/vfwscanf.c: Likewise.
2004-07-27 00:06:07 +00:00
Danny Smith 756301b7de * include/_mingw.h: Use only two underscores to uglify
__MINGW_ATTRIB_* macros.
	* include/stdlib.h: Adjust __MINGW_ATTRIB_* tokens.
	* includ/setjmp.h: Likewise.

	* include/sting.h: Add __MINGW_ATTRIB_PURE to locale-independent
	string functions.
	(_strdup, strdup): Add __MINGW_ATTRIB_MALLOC.
2004-07-26 23:45:03 +00:00
Corinna Vinschen 2646298531 * fhandler_proc.cc (format_proc_cpuinfo): Remove Intel-specific flags
from /proc/cpuinfo on non-Intel processors. Added new AMD-specific
	flags. Changed Intel flag names to match Linux.
2004-07-26 13:19:03 +00:00
Corinna Vinschen 3bf0227220 * cygserver.conf: Describe relation between shmmaxpgs and SHMMAX. 2004-07-26 09:31:07 +00:00
Danny Smith dcbe26ba3c * include/_mingw.h: Use only two underscores to uglify
__MINGW_ATTRIB_* macros.
	* include/stdlib.h: Adjust __MINGW_ATTRIB_* tokens.
	* includ/setjmp.h: Likewise.

	* include/sting.h: Add __MINGW_ATTRIB_PURE to locale-independent
	string functions.
	(_strdup, strdup): Add __MINGW_ATTRIB_MALLOC.
2004-07-26 09:13:42 +00:00
Danny Smith 174e6ff064 * include/string.h: Group wide string functions together,
and protect with _WSTRING_DEFINED.
2004-07-26 04:12:11 +00:00
Danny Smith 69e26fe33c 2004-07-26 Hartmut Honisch <hhonisch@users.sourceforge.net>
* include/commctrl.h (TreeView_SetItemState): Define macro.
2004-07-25 21:23:27 +00:00
Danny Smith 751ba44030 * include/_mingw.h (_MINGW_ATTR_*): Replace with
__MINGW_ATTRIB_*.
	* include/stdlib.h (_ATTRIB_NORETURN): Replace with
	__MINGW_ATTRIB_NOREURN, throughout.
	(malloc): Declare with __MINGW_ATTRIB_MALLOC.
	(calloc): Likewise.
	(abs): Declare with __MINGW_ATTRIB_CONST.
	(labs): Likewise.
	(div): Likewise.
	(ldiv): Likewise.
	(lldiv): Likewise.
	(_rotl): Likewise.
	(_rotr): Likewise.
	(_lrotl): Likewise.
	(_lrotr): Likewise.
	* include/setjmp.h (longjmp): Add __MINGW_ATTRIB_NORETURN.
2004-07-25 11:23:43 +00:00
Christopher Faylor 634d51d94e * dcrt0.cc (dll_crt0_0): Use proper boolean arguments.
* pinfo.cc (pinfo::init): Don't consider MapViewOfFileEx error to be fatal if
exiting.
* pinfo.h (pinfo::init): Eliminate default argument and supply the argument in
the one case that needed it.
2004-07-24 19:18:58 +00:00
Danny Smith b92b36bd8a * include/wingdi.h (CMYK): Its fun to play with the C-M-Y-K.
(young man, young man,...)
2004-07-24 12:47:44 +00:00
Corinna Vinschen 65c5aa77fb * autoload.cc (GetNativeSystemInfo): Add.
(IsWow64Process): Add.
	* init.cc (respawn_wow64_process): New function.
	(dll_entry): If process has been started from a 64 bit
	process, call respawn_wow64_process.
	* uname.cc (uname): On 64 bit systems, use GetNativeSystemInfo.
	Show actual CPU type.
2004-07-24 09:41:34 +00:00
Danny Smith 61e6420f32 2004-07-24 Brodie Thiesfield <brofield@users.sourceforge.net>
* include/shlobj.h (FILEDESCRIPTOR): Unicode it.
	(FILEGROUPDESCRIPTOR): LIkewise.
2004-07-24 09:00:52 +00:00
Corinna Vinschen 061095b5a3 * dtable.cc (dtable::get_debugger_info): Make stderr r/w according
to SUSv3.
2004-07-23 09:04:59 +00:00
Corinna Vinschen 0544d11637 * fhandler_tty.cc (fhandler_tty_slave::open): Use requested flag
values also when copying fhandler from archetype.
2004-07-22 20:39:08 +00:00
Christopher Faylor 5b7534fec3 * pinfo.cc (pinfo::init): Print handle in hex when MapViewOfFile fails. 2004-07-22 18:25:52 +00:00
Danny Smith cc054d9d26 * include/_mingw.h: Undefine __attribute__.
(__MINGW_ATTR_NORETURN): New define.
	(__MINGW_ATTR_CONST): New define.
	(__MINGW_ATTR_MALLOC): New define.
	(__MINGW_ATTR_PURE): New define.
	(_CRTIMP, __cdecl, __stdcall, __UNUSED_PARAM): Ansi-fy
	expansions.
2004-07-21 10:59:54 +00:00
Corinna Vinschen 7d9c458d8f * shm.cc: Whitespace fixes. 2004-07-20 16:08:49 +00:00
Corinna Vinschen 96e949deaa * bsd_helper.cc: Whitespace fixes.
* bsd_mutex.cc: Ditto.
2004-07-20 16:06:14 +00:00
Christopher Faylor 325965583f revert erroneous checkin 2004-07-20 16:01:39 +00:00
Christopher Faylor 894c677711 * Makefile.in (clean): Remove cygwin.def since it is autogenerated. 2004-07-20 15:52:33 +00:00
Danny Smith f451556720 * include/time.h (__time64_t): Add missing ';'. 2004-07-19 22:51:38 +00:00
Corinna Vinschen bb3be323ba * transport.cc (transport_layer_base::~transport_layer_base): Remove.
* transport.h (transport_layer_base::~transport_layer_base): Ditto.
2004-07-19 14:04:51 +00:00
Corinna Vinschen bc2c51140c * fhandler_dsp.cc (fhandler_dev_dsp::Audio_out::init): Fix non-ISO
expression.
	* fhandler_floppy.cc (fhandler_dev_floppy::open): Remove unused
	variable.
	* fhandler_proc.cc (format_proc_meminfo): Fix compiler warning.
2004-07-19 13:13:48 +00:00
Corinna Vinschen f8e58afb11 * bsd_mutex.cc (win_priority): Actually calculate p from priority. 2004-07-19 13:12:00 +00:00
Danny Smith cd341e5613 * include/math.h: Guard ISO C99 additions with __cplusplus
not __GLIBCPP__.
2004-07-17 05:15:26 +00:00
Christopher Faylor 241422d046 * Makefile.in (CC): Strip inappropriate include file settings from any
passed-in CC.
2004-07-17 04:31:14 +00:00
Christopher Faylor 1d2fd38847 * pinfo.cc (pinfo::init): Guard against MapViewOfFileEx failure. 2004-07-16 15:49:22 +00:00
Corinna Vinschen e348b39a71 * mmap.cc (mmap_record::alloc_page_map): Mark pages as allocated even
on Windows 9x, FWIW.
2004-07-16 14:32:03 +00:00
Joshua Daniel Franklin 99d86313f4 * how-resources.texinfo: Update documentation to /usr/share/doc.
* how-using.texinfo: Add paragraph about find -noleaf.
2004-07-16 14:17:15 +00:00
Danny Smith 75ccca2f65 2004-07-15 "dgun" <dgun@umpire.com>
* include/complex.h (conj): Correct typo in prototype.
2004-07-15 20:20:22 +00:00
Corinna Vinschen 0c0ad23a2c * mmap.cc (mprotect): When MAP_WRITE protection is requested, use
READWRITE or WRITECOPY protection, whatever has been used when the
	page has been allocated initially.
2004-07-15 17:00:44 +00:00
Corinna Vinschen 4243412aa5 * fhandler.h (class fhandler_dev_raw): Remove is_writing flag.
Remove declaration of writebuf.
	(class fhandler_dev_floppy): Remove declaration of close.
	* fhandler_floppy.cc (fhandler_dev_floppy::close): Delete.
	(fhandler_dev_floppy::lseek): Remove calls to writebuf.  Set
	eom_detected to false after successful seek.
	* fhandler_raw.cc (fhandler_dev_raw::writebuf): Delete.
	(fhandler_dev_raw::raw_read): Remove calls to writebuf.
	(fhandler_dev_raw::raw_write): Always invalidate buffer.
2004-07-15 14:56:05 +00:00
Danny Smith fcedcf9488 Whitespace change to ChangeLog 2004-07-15 11:56:01 +00:00
Danny Smith 4bf283e0e2 * include/math.h: Add pragma GCC system_header. 2004-07-15 11:39:15 +00:00
Danny Smith e651690002 * mingwex/complex/cargs.c: New file.
* mingwex/Makefile.in: Really add carg.o to libmingwex.a.
2004-07-15 11:35:13 +00:00
Corinna Vinschen a062ed9840 * Makefile.in (INCLUDES): Temporarily revert previous change.
* mingwex/Makefile,in (INCLUDES): Ditto.
	* profile/Makefile,in (INCLUDES): Ditto.
	* mingwex/Makefile,in: Drop carg.o dependency.
2004-07-15 10:40:37 +00:00
Corinna Vinschen 5ba42c7f4c * mmap.cc (class mmap_record): Fix return type of get_offset.
(mmap_record::fixup_page_map): Fix off by one error.
	(list::search_record): Use long as type of "start" argument in both,
	declaration and definition.  Use long as type for local variable "i".
2004-07-15 09:21:16 +00:00
Christopher Faylor a671e18c42 * mingwex/fwide.c: Include <stdio.h> to resolve FILE usage. 2004-07-15 02:43:19 +00:00
Christopher Faylor 839677149f * fhandler_registry.cc (registry_listing): Correct typo.
(fhandler_registry::fill_filebuf): Set size of newly expanded buffer prior to
calling RegQueryValueEx.
2004-07-15 02:07:14 +00:00
Danny Smith 8e47f4464b * Makefile.in (INCLUDES): Designate $(srcdir)/../include as a
system dir.
	* mingwex/Makefile,in (INCLUDES): Ditto.
	* profile/Makefile,in (INCLUDES): Ditto.

	* mingwex/Makefile,in: Add carg.o to libmingwex.a.
2004-07-14 23:44:50 +00:00
Corinna Vinschen dd3a7a2042 * fhandler_raw.cc (fhandler_dev_raw::raw_write): Remove buffered
write entirely.
2004-07-14 13:51:17 +00:00
Earnie Boyd 650bcf9d74 * Makefile.in: Move use of --nostdinc++ as GCC3.4 warns to use it
for C modules.
	* mingwex/Makefile.in: Ditto.
	* profile/Makefile.in: Ditto.
2004-07-13 13:01:28 +00:00
Earnie Boyd bb8c8bd47a * Makefile.in: Move use of --nostdinc++ as GCC3.4 refuses to use it
for C modules.
2004-07-13 11:23:08 +00:00
Earnie Boyd ef72590eb1 * include/limits.h: Change to new file header preamble. 2004-07-13 11:11:36 +00:00