Commit Graph

4064 Commits

Author SHA1 Message Date
Corinna Vinschen 97cb9b9de4 * fhandler_serial.cc (fhandler_serial::tcflush): Simplify. Remove
read polling loop to avoid a hang with streaming devices.
2003-12-11 18:07:42 +00:00
Christopher Faylor 992406a5ea * pinfo.cc (_pinfo::set_ctty): Correct stupid typo. 2003-12-11 06:19:36 +00:00
Christopher Faylor 8e10c4311f * cygheap.h (cygheap_types): Add HEAP_ARCHETYPES.
(init_cheap::ctty): Change to pointer.
* dtable.h (dtable::find_archetype): Declare new function.
(dtable::add_archetype): Declare new function.
(dtable::delete_archetype): Declare new function.
(dtable::narchetypes): Declare.
(dtable::farchetypes): Declare.
(dtable::initial_archetype_size): Declare.
(dtable::dtable): Initialize new fields.
(dtable::initial_archetype_size): Declare.
* dtable.cc (dtable::find_archetype): Define new function.
(dtable::add_archetype): Define new function.
(dtable::delete_archetype): Define new function.
(dtable::initial_archetype_size): Define.
* fhandler.h (fhandler_base::archetype): Declare.
(fhandler_base::usecount): Declare.
* fhandler.cc (fhandler_base::fhandler_base): Initialize new fields.
* fhandler_console.cc (fhandler_console::get_tty_stuff): Pass NULL to third
argument of set_ctty.
* fhandler_tty.cc (fhandler_tty_slave::open): Accommodate new archetype method
to create only one instance of a tty.
(fhandler_tty_slave::close): Don't close handles unless archetype usecount is
zero.  When that happens, close archetype too.
(fhandler_tty_slave::dup): Just copy archetype.  Set use count appropriately.
Set ctty, if appropriate.
(fhandler_tty_common::dup): Remove slave considerations.
(fhandler_tty_common::set_close_on_exec): Remove cygheap->ctty considerations.
* pinfo.cc (_pinfo::set_ctty): Accommodate new archetype methods.
* pinfo.h (_pinfo::set_ctty): Make third argument explicit.
* syscalls.cc (close_all_files): Decrement controlling tty use count before
closing all handles to allow controlling tty to be closed.  Remove previous
controlling tty considerations.
2003-12-11 06:12:41 +00:00
Christopher Faylor 3f23411449 remove debug output 2003-12-10 04:08:50 +00:00
Christopher Faylor ce40c6baf7 * fhandler_tty.cc (fhandler_tty_common::dup): Just copy cygheap->ctty to child
if duping the current ctty.
(fhandler_tty_common::close): Move debugging statement earlier in function.
(fhandler_tty_slave::close): Return success when closing ctty.
* syscalls.cc (close_all_files): Avoid calling fhandler_tty_slave close method
so that open_fhs will not be decremented when closing cygheap ctty.
(setsid): Ditto.
* dcrt0.cc (do_exit): Reorganize to avoid leaving a critical section active
after vfork.
* fhandler.h (fhandler_tty_slave::get_unit): Remove regparm parameter since it
can't work in a virtualized function.
2003-12-10 03:19:19 +00:00
Christopher Faylor 7176387b4f * pinfo.cc (_pinfo::set_ctty): Don't copy over existing ctty if it is active. 2003-12-09 03:27:05 +00:00
Danny Smith 91ec94b67c 2003-12-08 Danny Smith <dannysmith@users.sourceforge.net>
* include/winuser.h (DISPLAY_DEVICE_*): Remove defines.
	* include/wingdi.h  (DISPLAY_DEVICE_REMOVABLE,
	DISPLAY_DEVICE_MODESPRINED): Add defines from winuser.h

2003-12-08  Hartmut Honisch  <hhonisch@users.sourceforge.net>

	* include/commctrl.h (ListView_Get_State, ListView_Check_State):
	Add macros.
	* include/wingdi.h  (DISPLAY_DEVICE_*): Add multi-monitor
	constants.
	* include/shlobj.h (SHCOLUMNINIT); Add structure.
	(SHCOLUMNDAT): Likwise.
	(SHCOLUMNID): Likewise.
	(SHCOLUMNINFO): Likewise.
	(SHCOLSTATE): Add enum.
	(IColumnProvider): Add COM interface.
	(IQueryInfo): Likewise.
	(IShellIconOverlayIdentifier): Likewise.
  	* include/shlguid.h (IID_IColumnProvider) Declare.
	(IID_IQueryInfo): Likweise.
	(IID_IShellIconOverlayIdentifier): Likwise.
	* lib/shell32.c (IID_IColumnProvider) Define.
	(IID_IQueryInfo): Likweise.
	(IID_IShellIconOverlayIdentifier): Likwise.
2003-12-08 22:41:44 +00:00
Danny Smith ddd3eeee8c 2003-12-08 Roald Ribe <rrib@users.sourceforge.net>
* include/winuser.h (RT_MANIFEST): Add define.

2003-12-08  Pascal Buhler <pbuhler@users.sourceforge.net>

	* include/oleidl.h (IViewObject2): Inherit from IViewObject.
2003-12-08 19:37:19 +00:00
Christopher Faylor ac5ba8b0de * thread.cc (pthread::precreate): Delete duplicate setting of cancel_event. 2003-12-08 06:32:46 +00:00
Christopher Faylor da915a3aa6 * fhandler.h (fhandler_tty_slave::ttyname): Use name from pc since it is
guaranteed to be accurate.
* fhandler_tty.cc (fhandler_tty_slave::open): Increment open_fhs appropriate
when copying ctty.
(fhandler_tty_slave::close): Remove special case handling for exit_state.  Use
ctty < 0 check instead.
(fhandler_tty_common::close): Set io_handle to NULL after closing.
* syscalls.cc (close_all_files): Specifically close cygheap->ctty, if
appropriate.
2003-12-08 06:27:05 +00:00
Christopher Faylor 1b11f4fd72 * wait.cc (wait4): Move sawsig initialization inside loop. 2003-12-08 00:22:56 +00:00
Christopher Faylor 1c5c9a6bfb * spawn.cc (spawn_guts): Change type back to 'int' after erroneous change
below.
2003-12-08 00:21:17 +00:00
Christopher Faylor 2e008fb91f Change use of BOOL, TRUE, FALSE to bool, true, false, as appropriate,
throughout.
* tty.cc (tty::common_init): Remove call to SetKernelObjectSecurity and edit
some comments.
* cygheap.h (init_cygheap::ctty): Add new element.
* devices.in (device::parse): Remove special handling for /dev/tty.
* devices.cc: Regenerate.
* dtable.cc (build_fh_pc): Don't reset /dev/tty device.  Let the device opener
do that.
* fhandler_termios.cc (tty_min::set_ctty): Redefine to _pinfo class.
* fhandler_tty.cc (fhandler_tty_common::set_close_on_exec): Avoid setting
noninherit flag for ctty.
* tty.h: Move BOOLs to bools.
(tty_min::set_ctty): Redeclare to _pinfo class.
* pinfo.cc (_pinfo::set_ctty): Define new function based on tty_min::set_ctty.
Change first argument from tty number to tty_min class.
* pinfo.h (_pinfo::set_ctty): Declare.
* fhandler_console.cc (fhandler_console::get_tty_stuff): Reflect move of
set_ctty to _pinfo class.
* fhandler_tty.cc (fhandler_tty_slave::open): Treat FH_TTY specially.  Use
saved cygheap value if it exists.  Otherwise convert to real device and save on
first time open.
(fhandler_tty_common::dup): Potentially set controlling tty if duping a slave
tty.
* syscalls.cc (setsid): Close controlling tty in cygheap.
* tty.cc: Change some BOOLs to bools.
2003-12-07 22:37:12 +00:00
Corinna Vinschen 2e3ff06d3c * syscalls.cc (locked_append): New.
(updwtmp): Remove mutex code and call locked_append.
	(pututline): Ditto.
2003-12-07 12:56:59 +00:00
Christopher Faylor ae2543ed76 * exceptions.cc (_threadinfo::remove): Avoid a linked list walk. 2003-12-07 03:27:51 +00:00
Christopher Faylor 73262d7a44 * cygtls.h (_threadinfo::find_tls): New function.
* exceptions.cc (_threadinfo::find_tls): Rename from find_tls.  Use critical
section to protect access to linked list.
2003-12-07 02:56:52 +00:00
Christopher Faylor fcc47fd001 * exceptions.cc (_threadinfo::remove): Avoid returning without unlocking
critical section in the (hopefully impossible) case of an unrecognized thread.
2003-12-07 02:33:31 +00:00
Christopher Faylor 2b6d15a908 * cygtls.h: Add more "don't parse this" guards.
(_threadinfo::init_thread): Rename from 'init'.
(_threadinfo::init): Declare new function.
(_threadinfo::protect_linked_list): Declare new critical section.
* dcrt0.cc (dll_crt0_1): Call init_thread to initialize thread stuff.
(_dll_crt0): Call _threadinfo::init prior to invoking dll_crt0_1.
* exceptions.cc (_threadinfo::init_thread): Rename from 'init'.
(_threadinfo::init): Define new function.  Protect linked list manipulation
with new critical section.
(_threadinfo::call): Reflect function name change.
(_threadinfo::remove): Protect linked list manipulation with new critical
section
* gentls_offsets: Rework to allow multi-line "don't parse this" protection.
* init.cc (dll_entry): Don't remove threads info stuff here since the remove
function uses a critical section which can't be used during thread creation or
destruction.
* thread.cc (pthread::exit): Call _threadinfo remove function here.
2003-12-06 18:08:38 +00:00
Christopher Faylor aeab6ea658 * cygthread.cc (cygthread::stub2): Remove myself from the list of threads
monitored by signals since this thread will never call raise or sigwait.
(cygthread::simplestub2): Ditto.  Set ev here.
(cygthread::cygthread): Don't set ev here for freerange thread.
2003-12-05 05:29:17 +00:00
Christopher Faylor 78f3155ced * path.cc (slash_unc_prefix_p): Allow '.' as a valid character after '\\' in a
UNC path.
2003-12-05 04:33:40 +00:00
Christopher Faylor 57e6aca667 * exceptions.cc (setup_handler): Remove ill-advised debugging output. 2003-12-05 04:20:48 +00:00
Corinna Vinschen 592db10ed7 * include/cygwin/types.h (struct __fcntl64): Fix datatype of l_start. 2003-12-04 09:37:55 +00:00
Corinna Vinschen 145b4dc249 Substitute 0x7fffffff and 0xffffffff by INT32_MAX and UINT32_MAX
throughout, except in assembler code.
2003-12-03 16:35:52 +00:00
Corinna Vinschen d2fa946e51 * fhandler_disk_file.cc (fhandler_disk_file::lock): Use UINT32_MAX
instead of 0xffffffff.  Accomodate Win 9x bug in evaluating length
	of area to lock when given length is 0.
2003-12-03 11:22:49 +00:00
Corinna Vinschen 1843517401 * fhandler_disk_file.cc (fhandler_disk_file::lock): Interchange
values of off_low and off_high.
2003-12-03 09:58:23 +00:00
Corinna Vinschen e2a39e2efa * fcntl.cc (fcntl_worker): Remove static storage class.
* flock.cc (flock): Use struct __flock64. Call fcntl_worker.
	Use Cygwin errno functions instead of accessing errno directly.
	* winsup.h: Declare fcntl_worker.
2003-12-03 09:55:42 +00:00
Corinna Vinschen 941c9bf805 * fcntl.cc (_fcntl): Whitespace cleanup. 2003-12-03 09:16:37 +00:00
Christopher Faylor d1eb7a4615 * cygthread.cc (cygthread::stub): Properly establish _threadinfo environment.
(cygthread::stub2): New function.
(cygthread::simplestub): Ditto.
(cygthread::simplestub2): New function.
* cygthread.h (cygthread::stub2): Declare new function.
(cygthread::simplestub2): Ditto.
* cygtls.h (_threadinfo::call): Declare new function.
(_threadinfo::call2): Ditto.
* dcrt0.cc (dll_crt0_1): Accommodate new _threadinfo::init which doesn't return
pointer to tls.
(_dll_crt0): Remove obsolete DECLARE_TLS_STORAGE.
(dll_crt0): Ditto.
* exceptions.cc (_threadinfo::call): New function.
(_threadinfo::call2): Ditto.
(_threadinfo::init): Don't return pointer.
* thread.cc (pthread::thread_init_wrapper): Properly establish _threadinfo
environment.
(pthread::thread_init_wrapper2): New function.
* thread.h (pthread::thread_init_wrapper): Remove noreturn attribute
(pthread::thread_init_wrapper2): Declare new function.
* winbase.h: Remove obsolete code.
2003-12-03 05:21:55 +00:00
Christopher Faylor af9ef8abb2 * Makefile.in: Change the way that -f options are appended to CFLAGS, slightly. 2003-12-03 00:21:21 +00:00
Christopher Faylor e575a697ba * fcntl.cc (_fcntl): Silence a compiler warning. 2003-12-02 23:47:28 +00:00
Christopher Faylor 93e4038242 * pinfo.cc (pinfo::init): Use shared_name to construct the mapname. 2003-12-02 04:10:56 +00:00
Christopher Faylor 5c9cceced7 white space 2003-12-02 01:36:08 +00:00
Thomas Pfaff 693dd53815 Change tab to space in Changelog. 2003-12-01 22:13:58 +00:00
Thomas Pfaff 94d2416049 * thread.cc (pthread_rwlock::add_reader): Remove mx parameter for
List_insert call.
(pthread::prepare): Ensure race safeness when adding function
pointers to atfork lists by using List_insert.
* thread.h (List_insert): Use InterlockedCompareExchangePointer to
ensure race safeness without using a mutex.
(List_remove): Use InterlockedCompareExchangePointer to
ensure race safeness with List_insert.
(List::insert): Remove mx parameter for	List_insert call.
2003-12-01 22:10:57 +00:00
Corinna Vinschen bd16a3a8a8 * winsup.api/known_bugs.tcl: Remove fcntl09 and fcntl10. These
tests had a compatibility bug.
	* winsup.api/ltp/fcntl09.c: Don't use F_RDLCK | F_WRLCK but only
	F_WRLCK to set a write lock.
	* winsup.api/ltp/fcntl10.c: Ditto.
2003-12-01 17:33:11 +00:00
Corinna Vinschen dc3998682a * Makefile.in (OBSOLETE_FUNCTIONS): Add fcntl.
(NEW_FUNCTIONS): Add fcntl64.
	* cygwin.din: Export fcntl64.  Make fcntl being SIGFE.
	* fcntl.cc (fcntl_worker): New function.
	(fcntl64): New function.
	(_fcntl): Call fcntl_worker.  Convert 32 bit flock structure into
	64 bit flock structure and vice versa.
	* fhandler.cc (fhandler_base::lock): Change 2nd parameter to
	struct __flock64 *.
	* fhandler_disk_file.cc (fhandler_disk_file::lock): Ditto.  Rework
	to be 64 bit aware.
	* fhandler.h: Accomodate above method argument changes.
	* include/cygwin/types.h: Add struct __flock32 and __flock64.
	Define struct flock according to setting of __CYGWIN_USE_BIG_TYPES__.
	* include/cygwin/version.h: Bump API minor number.
2003-12-01 17:26:28 +00:00
Corinna Vinschen 6c2b784612 * cygheap.cc (cygheap_init): Set cygheap->shared_prefix.
* cygheap.h (struct init_cygheap): Add shared_prefix.
	* shared.cc (shared_name): Use cygheap->shared_prefix.
2003-12-01 15:03:43 +00:00
Corinna Vinschen 4febe95f89 * shared.cc (shared_name): Take into account the SE_CREATE_GLOBAL_NAME
privilege when building the name string.
	(open_shared): Remove the call to OpenFileMapping.
	(shared_info::initialize): Move cygheap initialization to ...
	(memory_init): ... here. Suppress now useless shared_h variable.
	(user_shared_initialize): Make tu a cygpsid.
2003-12-01 11:16:20 +00:00
Corinna Vinschen cb766c47bb * include/tzfile.h: Remove duplicate definition of TM_SUNDAY.
* localtime.cc: Point TZDIR to the /usr/share/zoneinfo directory used
	by the tzcode package.
2003-12-01 10:39:17 +00:00
Danny Smith 635fa4ba48 * include/winnt.h (GetCurrentFiber): Remove duplicate prototype.
(GetFiberData); Likewise.

	(GetCurrentFiber): Change volatile to __volatile__.
	(GetFiberData); Likewise.
2003-12-01 09:11:42 +00:00
Corinna Vinschen b406ed7b51 * flock.cc: Renamed from flock.c. 2003-11-30 10:43:04 +00:00
Christopher Faylor fcac349166 * pinfo.h: Remove global_sigs declaration.
* siginfo.h: Move global_sigs declaration here.
* Makefile.in: Remove duplicate compiler flag.
2003-11-30 02:21:04 +00:00
Christopher Faylor b63ba3b6aa * exceptions.cc (_threadinfo::pop): Zero *contents* of popped stack location
rather than the actual stack pointer.
2003-11-30 02:19:45 +00:00
Corinna Vinschen f3a1e23eb3 * Makefile.in: (DLL_OFILES): Add flock.o.
* cygwin.din: Export flock.
	* flock.c: New file.
	* include/sys/file.h: Include sys/cdefs.h.
	Add function prototype for flock().
	Add some comments from BSD's header for further clarity.
	(L_SET, L_CURR, L_INCR, L_XTND): Redefine as the macros
	SEEK_SET, SEEK_CUR, SEEK_CUR, & SEEK_END respectively.
	(LOCK_SH,LOCK_EX,LOCK_NB,LOCK_UN): New macros for flock().
	* include/cygwin/version.h: Bump API minor number.
2003-11-29 23:00:51 +00:00
Christopher Faylor b50fe8212f * sigproc.cc (no_signals_available): Fix so that non-zero exit state is a true
condition rather than errnoneously only checking other states when exist_state
was zero.
2003-11-29 00:31:37 +00:00
Christopher Faylor 62e070d72e * pinfo.h (_pinfo::getthread2signal): Remove obsolete function.
* cygtls.h (_threadinfo): Define tid more precisely.
(_threadinfo::operator HANDLE): Define.
* exceptions.cc (_threadinfo::interupt_now): Use _threadinfo HANDLE operator to
derive thread handle.
(setup_handler): Ditto.
* sigproc.cc: Reorganize includes.
2003-11-29 00:26:40 +00:00
Christopher Faylor 13584f077b * pinfo.h (_pinfo::getsig): Remove obsolete function, here and throughout.
* exceptions.cc: Ditto.
* fhandler_termios.cc: Ditto.
* signal.cc: Ditto.
* sigproc.cc: Ditto.
* Makefile.in: Revert previous change which made a cygwin.din newer than a
version.h a warning rather than an error.
2003-11-28 22:13:57 +00:00
Christopher Faylor 74d893b13c * cygwin.din: Re-add inexplicably missing semaphore/msg functions. 2003-11-28 21:39:08 +00:00
Christopher Faylor 965f78cbbe * gendevices: Issue error when shilka is missing. 2003-11-28 21:20:15 +00:00
Christopher Faylor abd2fa9994 * include/cygwin/signal.h: New file.
(also check in tlsoffsets.h, missed by previous checkin)
2003-11-28 21:01:09 +00:00
Christopher Faylor 9a4d574b8d Eliminate use of sigframe and sigthread throughout.
* Makefile.in (DLL_OFILES): Add sigfe.o.  Remove reliance on cygwin.def from
cygwin0.dll dependency since dependence on sigfe.o implies that.  Generate def
file on the fly using 'gendef'.
* configure.in: Don't auto-generate cygwin.def.
* configure: Regenerate.
* cygwin.din: Add SIGFE stuff where appropriate.
* dcrt0.cc (dll_crt0_1): Initialize cygwin tls early in process startup.  Set
_main_tls to address of the main thread's cygwin tls.
* debug.h: Remove now unneeded WFSO and WFMO declarations.
* exceptions.cc (_last_thread): Define.
(set_thread_state_for_signals): New function.
(reset_thread_exception_for_signals): Ditto.
(init_thread_for_signals): Ditto.
(delete_thread_for_signals): Ditto.
(capture_thread_for_signals): Ditto.
(handle_exceptions): Set return address explicitly for exceptions prior to
calling sig_send.
(interrupt_on_return): Eliminate.
(setup_handler): Add preliminary implementation for dealing with
thread-specific signals by querying _main_tls.
(signal_exit): Use cygthread::main_thread_id instead of mainthread.id.
(call_signal_handler_now): For now, just handle the main thread.
* fork.cc (vfork): Save and restore main _my_tls.
* gendef: New file.  Generates def file and sigfe.s file.
* gentls_offsets: New file.  Generates offsets for perl to use in sigfe.s.
* how-signals-work.txt: Mention that info is obsolete.
* init.cc (dll_entry): Initialize cygwin tls storage here.
* miscfuncs.cc (low_priority_sleep): Make a C function for easier calling from
asm.
* perthread.h (vfork_save::tls): New element.
* signal.cc (nanosleep): Replace previous use of
sigframe.call_signal_handler_now with straight call to call_signal_handler_now.
(abort): Ditto.
* syscalls.cc (readv): Ditto.
* termios.cc (tcsetattr): Ditto.
* wait.cc (wait4): Ditto.
* sigproc.cc (sig_dispatch_pending): Ditto.
(sig_send): Ditto.
* sigproc.h: Declare call_signal_handler_now.
* thread.cc (pthread::thread_init_wrapper): Initialize cygwin tls.  Remove
obsolete and unworking signal stuff.
* thread.h (verifyable_object::sigs): Eliminate.
(verifyable_object::sigmask): Eliminate.
(verifyable_object::sigtodo): Eliminate.
(verifyable_object::exit): Make attribute noreturn.
(verifyable_object::thread_init_wrapper): Ditto.
(pthread_null::exit): Ditto.
* winbase.h (__stackbase): Always define.
* winsup.h (low_priority_sleep): Declare as a "C" function.
* include/cygwin/version.h: Bump API version to reflect sigwait export.
* include/sys/queue.h: Protect SLIST_ENTRY from previous declaration.
* signal.cc (sigwait): Implement.
* select.cc (fhandler_base::ready_for_read): Add debugging output.
* devices.h: Define more device pointers via their storage.
* devices.in: Don't parse things like /dev/inet/tcp, as they really have no
meaning.
* devices.cc: Regenerate.
* gendevices: Set proper protection for output file.
* cygtls.h: New file.
* gendef: New file.
* gentls_offsets: New file.
* tlsoffsets.h: New file.  Autogenerated.
* config/i386/longjmp.c: Remove.  File subsumed by gendef output.
* config/i386/makefrag: Remove obsolete file.
* fhandler.cc: Remove spurious access_worker declaration.
* spawn.cc (spawnve): Make debugging output more accurate.
* cygwin-gperf: Remove.
* devices.cc: Remove.
2003-11-28 20:55:59 +00:00
Christopher Faylor ffe0063843 * speclib: Use correct EOF marker. Ensure that directory is actually deleted
when running under Windows.
2003-11-28 20:51:11 +00:00
Christopher Faylor 268aec4006 * speclib: Use correct EOF marker. Ensure that directory is actually deleted
when running under Windows.
2003-11-28 20:10:07 +00:00
Christopher Faylor 8cf11e2918 * lib/Makefile.in: Use make function to locate .mri file to allow building in
directory other than source directory.
2003-11-27 23:34:18 +00:00
Christopher Faylor 93eba3cb60 * fhandler_disk_file.cc (fhandler_disk_file::readdir): Reorganize to avoid
inappropriate .lnk extensions with munged filenames under managed mode.
2003-11-27 23:27:23 +00:00
Danny Smith 714b947a1b 2003-11-27 Dimitry Sibiryakov <aafemt@users.sourceforge.net>
* include/signal.h (SIG_SGE, SIG_ACK): Add defines.
2003-11-27 08:23:43 +00:00
Danny Smith d799adc46f * lib/vfw32.def: Remove, replacing with ...
* lib/msvfw32.def: New file.
	* lib/avicap32.def: New file.
	* lib/avifil32.def: New file.
	* lib/vfw32.mri: New file.
	* Makefile.in: (MRI_FILES, MIMPLIBS): New vars for
	import libs with multiple dll's.
	(LIBS): Add MIMPLIBS.
	(DISTFILES): Add MRI_FILES.
	(libvfw32.a): Build using mri script.
2003-11-27 02:14:37 +00:00
Corinna Vinschen 1d88f8cea2 * cygserver.cc (main): Move call to ipcinit() up before installing
any threads.
	* sysv_sem.cc: Update to FreeBSD version 1.67.
	(seminit): Initialize semaphore sequence numbers to 0.
2003-11-26 22:29:35 +00:00
Corinna Vinschen a2acbfb14e * Makefile.in (CYGWIN_LIB): Variable pointing to libcygwin.a in
the parallel cygwin dir.
	(cygserver.exe): Depend on and link against $CYGWIN_LIB.
2003-11-26 20:05:09 +00:00
Corinna Vinschen f25babdf07 * mkgroup.c (main): Print "root" group with local admins group sid
and gid 0.
2003-11-26 15:47:44 +00:00
Corinna Vinschen cb55867514 * sec_helper.cc (set_process_privilege): Rename restore_priv to
priv_luid.

	* sec_helper.cc (set_process_privilege): Call LookupPrivilegeValue
	before opening the token.
2003-11-26 14:29:22 +00:00
Corinna Vinschen 12069cf31b * dir.cc (mkdir): Use local security_descriptor. Call
set_security_attribute appropriately.
	* external.cc (cygwin_internal): Ditto.
	* fhandler.cc (fhandler_base::open): Ditto.
	* fhandler_socket.cc (fhandler_socket::bind): Ditto.
	* path.cc (symlink_worker): Ditto.
	* sec_acl.cc (setacl): Ditto. Call read_sd appropriately.
	(getace): Ditto.
	* sec_helper.cc (security_descriptor::malloc): New method.
	(security_descriptor::realloc): New method.
	(security_descriptor::free): New method.
	* security.cc (read_sd): Get security_descriptor as parameter instead
	of PSECURITY_DESCRIPTOR and a size. Drop unnecessary parameter check.
	Allocate the security_descriptor buffer according to size returned by
	a call to GetFileSecurity. Return buffer size on success.
	(write_sd): Get security_descriptor as parameter instead of
	PSECURITY_DESCRIPTOR and a size.
	(get_nt_attribute): Use local security_descriptor.
	(get_nt_object_attribute): Ditto in case of type == SE_REGISTRY_KEY.
	Allocate security_descriptor buffer according to size returned by
	a call to RegGetKeySecurity.
	(alloc_sd): Make static. Get security_descriptor as parameter instead
	of PSECURITY_DESCRIPTOR and a size. Drop unnecessary parameter check.
	(set_security_attribute): Get security_descriptor as parameter instead
	of PSECURITY_DESCRIPTOR and a size.
	(set_nt_attribute): Use local security_descriptor.
	(check_file_access): Ditto.
	* security.h: Add class security_descriptor.
	(read_sd): Change declaration to get security_descriptor as parameter
	instead of PSECURITY_DESCRIPTOR and a size.
	(write_sd): Ditto.
	(set_security_attribute): Ditto.
	(alloc_sd): Remove declaration.
	* thread.cc (semaphore::semaphore): Use local security_descriptor. Call
	set_security_attribute appropriately.
2003-11-26 13:23:27 +00:00
Corinna Vinschen 3db690789f * sec_acl.h (getace): Use FILE_*_BITS as permission mask.
* security.cc (get_attribute_from_acl): Ditto.
	* security.h (FILE_READ_BITS): Define to match also GENERIC bits.
	(FILE_WRITE_BITS): Ditto.
	(FILE_EXEC_BITS): Ditto.
2003-11-26 10:52:21 +00:00
Christopher Faylor af284c9c3b * Makefile.in (CXXFLAGS): Remove duplicate options handled in Makefile.common. 2003-11-26 03:52:12 +00:00
Christopher Faylor b5aa10cda8 more white space 2003-11-25 22:59:37 +00:00
Christopher Faylor 8861377a2d more white space 2003-11-25 22:58:32 +00:00
Christopher Faylor 970ca29242 more white space 2003-11-25 22:57:22 +00:00
Christopher Faylor 3654a9dd2f more white space 2003-11-25 22:56:58 +00:00
Christopher Faylor e2b9eb11e5 * thread.cc: Minor whitespace cleanup. Remove some obsolete code. 2003-11-25 22:55:31 +00:00
Christopher Faylor 84f08ba160 * winsup.api/known_bugs.tcl: Remove lseek10 since mknod now works. 2003-11-25 19:24:46 +00:00
Christopher Faylor e00700cd80 * dtable.cc (build_fh_name): Set error in dummy fhandler when one is noted
during path_conv.
* fhandler.h (fhandler_base::set_error): New method.
2003-11-25 02:03:17 +00:00
Christopher Faylor 46c6a3e8eb * configure.in: Avoid using cygserver unless hosting on cygwin. 2003-11-24 17:03:50 +00:00
Danny Smith 3ad60fc808 * include/winnt.h (PAGE_*): Group defines together. Change
constants to hex notation.
2003-11-23 20:29:02 +00:00
Christopher Faylor 4b1bc69287 white space 2003-11-23 17:55:37 +00:00
Corinna Vinschen 95b1156144 * Makefile.in: Make cygserver depending on cygwin. 2003-11-23 09:02:26 +00:00
Christopher Faylor 0af8d6110b * sigproc.cc (sig_send): Correct below checkin. Use
thisframe.call_signal_handler.
2003-11-23 05:42:47 +00:00
Christopher Faylor 0670609d12 * sigproc.cc (proc_exists): A zombie process does not exist.
(sig_send): Improve debugging output.  Wait for pipe to be created before
trying to send to it.  Call call_signal_handler_now if sending a signal to
myself.
2003-11-23 05:34:00 +00:00
Corinna Vinschen c026d84209 * msg.cc (client_request_msg::serve): Add default case to msgop switch.
* sem.cc (client_request_sem::serve): Add default case to semop switch.
	* shm.cc (client_request_shm::serve): Add default case to shmop switch.
2003-11-22 22:37:13 +00:00
Christopher Faylor 876083f32e * dcrt0.cc (check_sanity_and_sync): Correct api major version check so that
newer dlls will work with older apps but not vice versa.
2003-11-22 17:22:59 +00:00
Christopher Faylor ef7acb98aa * sem.cc: Always include signal.h to handle SIGSYS raise when !USE_SERVER.
* shm.cc: Ditto.
* msg.cc: Always include signal.h to handle SIGSYS raise when !USE_SERVER.
2003-11-21 22:22:08 +00:00
Christopher Faylor bfa2e9cbb1 * msg.cc: Always include signal.h to handle SIGSYS raise when !USE_SERVER. 2003-11-21 22:21:05 +00:00
Corinna Vinschen 4bd6628553 * Makefile.in (install): Explicitely create directories. Install
README to $(prefix)/share/doc/Cygwin.
	* README: New file.
2003-11-21 18:10:49 +00:00
Corinna Vinschen e74c79a870 * cygserver.cc (print_usage): Fix scrambled output. 2003-11-21 13:30:33 +00:00
Corinna Vinschen 94cacaf60b * cygserver-config: Slightly modify printed message. 2003-11-20 19:34:00 +00:00
Christopher Faylor d012506e3c * configure.in: Make --use-server the default.
* configure: Regenerate.
2003-11-20 19:31:52 +00:00
Christopher Faylor 7ee8258620 * configure.in: Make --use-server the default. Remove powerpc target.
* configure: Regenerate.
2003-11-20 19:31:41 +00:00
Corinna Vinschen d26c0ff955 * winsup.api/msgtest.c (main): Revert to use the SIGSYS signal handler.
* winsup.api/semtest.c (main): Ditto.
	* winsup.api/shmtest.c (main): Ditto.
2003-11-20 18:25:36 +00:00
Corinna Vinschen bd0e35213d * msg.cc (msgctl): Raise SIGSYS if call not available.
(msgget): Ditto.
	(msgrcv): Ditto.
	(msgsnd): Ditto.
	* sem.cc (semctl): Ditto.
	(semget): Ditto.
	(semop): Ditto.
	* shm.cc (shmat): Ditto.
	(shmctl): Ditto.
	(shmget): Ditto.
	(shmdt): Ditto.
2003-11-20 18:09:44 +00:00
Corinna Vinschen 72f11cac65 * Makefile.in (install): Install cygserver-config script to bindir.
* cygserver-config: New script.
2003-11-20 13:51:34 +00:00
Corinna Vinschen 2010ab333f * winsup.api/msgtest.c: New file derived from FreeBSD, testing
XSI Message Queue support.
	* winsup.api/semtest.c: Ditto, testing XSI Semaphore support.
	* winsup.api/shmtest.c: Ditto, testing XSI Shared Memory support.
2003-11-19 18:51:18 +00:00
Corinna Vinschen e545df31d5 * Makefile.in: Add rules to build ipcrm and ipcs.
* ipcrm.c: New file.
	* ipcs.c: New file.
2003-11-19 18:50:52 +00:00
Corinna Vinschen a6df500f7d * cygserver.h (client_request::request_code_t): Add
CYGSERVER_REQUEST_MSG and CYGSERVER_REQUEST_SEM.
	(admininstrator_group_sid): Add extern declaration.
	* cygserver_ipc.h: Rewrite.
	* cygserver_msg.h: New file.
	* cygserver_sem.h: New file.
	* cygserver_shm.h: More or less rewrite.
	* cygwin.din: Add msgctl, msgget, msgrcv, msgsnd, semctl, semget and
	semop.
	* msg.cc: Rewrite.
	* safe_memory.h: Remove.
	* sem.cc: Rewrite.
	* shm.cc: Rewrite.
	* include/cygwin/ipc.h: Use appropriate guard.
	(struct ipc_perm): Add seq.
	(IPCID_TO_IX): New define from BSD.
	(IPCID_TO_SEQ): Ditto.
	(IXSEQ_TO_IPCID): Ditto.
	(IPC_R): Ditto.
	(IPC_W): Ditto.
	(IPC_M): Ditto.
	* include/cygwin/msg.h: Use appropriate guard. #ifdef _KERNEL all stuff
	not explicitely defined by SUSv3. Use signed types in structs to match
	types used in BSD.
	(msgqnum_t): Define unsigned.
	(msglen_t): Ditto.
	(struct msqid_ds): Add msg_first and msg_last.
	(struct msginfo): Remove msgpool. Add msgssz and msgseg.
	* include/cygwin/sem.h: Use appropriate guard. #ifdef _KERNEL all stuff
	not explicitely defined by SUSv3. Use signed types in structs to match
	types used in BSD.
	(SEM_UNDO): Define appropriately.
	(struct semid_ds): Add sem_base.
	(struct seminfo): Add semmap and semusz.
	(SEM_A): New define from BSD.
	(SEM_R): Ditto.
	(SEM_ALLOC): Ditto.
	(union semun): Define.
	* include/cygwin/shm.h: Use appropriate guard. #ifdef _KERNEL all stuff
	not explicitely defined by SUSv3. Use signed types in structs to match
	types used in BSD.
	(SHMLBA): Define using cygwin_internal(CW_GET_SHMLBA) call.
	(struct shmid_ds): Add shm_internal.
	(struct shm_info): Rename shm_ids to used_ids as in BSD.  Add define
	for shm_ids.
	* include/cygwin/sysproto.h: New file.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/ipc.h: New file.
	* include/sys/msg.h: New file.
	* include/sys/queue.h: New file from BSD.
	* include/sys/sem.h: New file.
	* include/sys/shm.h: New file.
	* include/sys/sysproto.h: New file.
2003-11-19 18:50:23 +00:00
Corinna Vinschen 282113ba89 Don't use safe_new but new throughout. Fix copyright dates
throughout.
	* Makefile.in: Accomodate all new files and name changes.
	Add a *.d dependency.
	(sbindir): Add.
	(etcdir): Drop in favor of more appropriate sysconfdir definition.
	(sysconfdir): Add.
	(CXXFLAGS): Add -MMD flag. Add SYSCONFDIR definition.
	(.SUFFIXES): Add.
	(install): Add action items.
	(libclean): New target.
	(fullclean): Ditto.
	* bsd_helper.cc: New file.
	* bsd_helper.h: Ditto.
	* bsd_log.cc: Ditto.
	* bsd_log.h: Ditto.
	* bsd_mutex.cc: Ditto.
	* bsd_mutex.h: Ditto.
	* client.cc: Rearrange to build as less as possible if
	__INSIDE_CYGWIN__.
	(client_request::handle_request): Add Message Queue and Semaphore
	handling.
	* cygserver.cc: Rearrange to build as less as possible if
	__INSIDE_CYGWIN__. Use new debug/log/panic logging functions.
	(DEF_CONFIG_FILE): New definition for configuration file.  Use
	throughout.
	(getfunc): Remove.
	(__cygserver__printf): Remove.
	(client_request_attach_tty::serve): Return error if impersonation
	fails.
	(print_usage): Pump up help message.
	(print_version): Add output of default configuration file.
	(main): Accommodate new options.  Allow overwrite of threading options
	from config file.  Call several new initialization functions.  Drop
	printing dots.  Don't define SIGHANDLE inline.
	* cygserver.conf: New file.
	* cygserver_process.h: Rename to process.h.
	* cygserver_transport.h: Rename to transport.h.
	* cygserver_transport_pipes.h: Rename to transport_pipes.h.
	* cygserver_transport_sockets.h: Rename to transport_sockets.h.
	* msg.cc: Rewrite.
	* sem.cc: Rewrite.
	* shm.cc: Rewrite.
	* sysv_msg.cc: New file, derived from FreeBSD version 1.52.
	* sysv_sem.cc: New file, derived from FreeBSD version 1.66.
	* sysv_shm.cc: New file, derived from FreeBSD version 1.89.
	* threaded_queue.cc: Rearrange to build as less as possible if
	__INSIDE_CYGWIN__.
	* transport.cc (transport_layer_base::impersonate_client): Define bool.
	(transport_layer_base::revert_to_self): Ditto.
	* transport.h (transport_layer_base::impersonate_client): Declare bool.
	(transport_layer_base::revert_to_self): Ditto.
	* transport_pipes.cc (transport_layer_pipes::transport_layer_pipes):
	Don't call init_security.
	(init_security): Remove.
	(transport_layer_pipes::accept): Use global sec_all_nih.
	(transport_layer_pipes::connect): Ditto.
	(transport_layer_pipes::impersonate_client): Define bool.
	(transport_layer_pipes::revert_to_self): Ditt.
	* transport_pipes.h (transport_layer_pipes::impersonate_client): Declare
	bool.
	(transport_layer_pipes::revert_to_self): Ditto.
	* woutsup.h: Include bsd compatibility headers.
	(SIGHANDLE): Add definition.
	(__cygserver__printf): Remove definition.
	(__noop_printf): Ditto.
	(debug_printf): Define using debug.
	(syscall_printf): Define using log.
	(system_printf): Ditto.
	Drop all other _printf definitions.
2003-11-19 18:49:41 +00:00
Corinna Vinschen fcd3838ab5 * dtable.cc (build_fh_pc): Resurrect accidentally removed
DEV_CYGDRIVE_MAJOR case.
2003-11-19 11:19:27 +00:00
Corinna Vinschen 7326e3ffd9 Revert most of last check in to ChangeLog. It duplicated
accidentally a big bunch of old entries.
2003-11-19 10:11:46 +00:00
Corinna Vinschen 8f4dfcaa1f * fhandler.cc (fhandler_base::lseek): Include high order offset
bits in return value.
2003-11-17 22:18:42 +00:00
Corinna Vinschen 6e17cee57b * bsdlib.cc (getprogname): New function.
(setprogname): New funtion.
	* cygwin.din: Export getprogname and setprogname.
	* include/cygwin/version.h: Bumb API version number.
2003-11-17 17:25:59 +00:00
Christopher Faylor 490d129f4a * include/limits.h: Revert unsanctioned changes below.
* include/cygwin/config.h: Ditto.
* include/sys/param.h: Ditto.
2003-11-15 17:04:10 +00:00
Manu B 5cdbbdb385 Add Tab control macro 2003-11-15 01:00:06 +00:00
Robert Collins 95d02d5b9b 2003-11-11 Robert Collins <rbtcollins@hotmail.com>
Ron Parker <rdparker@butlermfg.com>

	* bsdlib.cc: Update throughout to use CYG_MAX_PATH rather than MAX_PATH.
	* cygheap.h: Ditto.
	* dcrt0.cc: Ditto.
	* delqueue.cc: Ditto.
	* dlfcn.cc: Ditto.
	* dll_init.cc: Ditto.
	* dll_init.h: Ditto.
	* dtable.cc: Ditto.
	* environ.cc: Ditto.
	* environ.h: Ditto.
	* exceptions.cc: Ditto.
	* external.cc: Ditto.
	* fhandler_disk_file.cc: Ditto.
	* fhandler_proc.cc: Ditto.
	* fhandler_process.cc: Ditto.
	* fhandler_raw.cc: Ditto.
	* fhandler_registry.cc: Ditto.
	* fhandler_socket.cc: Ditto.
	* fhandler_virtual.cc: Ditto.
	* miscfuncs.cc: Ditto.
	* mmap.cc: Ditto.
	* netdb.cc: Ditto.
	* path.cc: Ditto.
	* path.h: Ditto.
	* pinfo.cc: Ditto.
	* pinfo.h: Ditto.
	* pthread.cc: Ditto.
	* registry.cc: Ditto.
	* shared.cc: Ditto.
	* shared_info.h: Ditto.
	* smallprint.c: Ditto.
	* spawn.cc: Ditto.
	* strace.cc: Ditto.
	* syscalls.cc: Ditto.
	* thread.h: Ditto.
	* uinfo.cc: Ditto.
	* winsup.h: Ditto.
	* include/limits.h: Ditto.
	* include/cygwin/config.h: Ditto.
	* include/sys/param.h: Ditto.
2003-11-14 23:40:06 +00:00
Corinna Vinschen 508682370b * mkgroup.c: Avoid compiler warnings throughout.
* mkpasswd.c: Ditto.
	* passwd.c: Ditto.
2003-11-14 19:14:43 +00:00
Christopher Faylor 22ec16a830 * dtable.cc (build_fh_pc): Use DEV_SERIAL_MAJOR to catch all serial ports.
Remove redundant FH_CYGDRIVE case since it is handled by DEV_CYGDRIVE_MAJOR.
2003-11-14 01:37:23 +00:00
David Starks-Browning d15d293f97 minor adjustments to Elfyn's contribution. 2003-11-13 22:23:59 +00:00
David Starks-Browning 10c43de319 Apply Elfyn's patches as supplied in <http://cygwin.com/ml/cygwin-patches/2003-q3/msg00156.html>. 2003-11-13 22:07:36 +00:00
Danny Smith cbae134251 2003-11-13 Martin Fuchs <martin-fuchs@gmx.net>
* include/shlobj.h (ILAppendID, ILClone, ILCloneFirst, ILCombine,
	ILFindChild, ILFindLastID, ILFree, ILGetNext, ILGetSize, ILIsEqual,
	ILIsParent, ILLoadFromStream, ILRemoveLastID, ILSaveToStream):
	Add prototypes.
	* lib/shell32.def: Add stubs.

	* include/commctrl.h (ListView_FindItem): Add type cast to avoid
	compiler warnings.

2003-11-13  Hans Leidekker <hans@it.vu.nl>

	* include/winbase.h (WIN32_STREAM_ID): Correct typedef.
2003-11-13 09:43:08 +00:00
Thomas Pfaff 068834a10f * thread.cc (pthread::exit): Cleanup on thread exit.
(__reent_t::init_clib): Set thread local clib __cleanup var
appropriately.
2003-11-11 19:10:47 +00:00
Christopher Faylor 8398809e7d * miscfuncs.cc (low_priority_sleep): Make a "C" function.
* winsup.h (low_priority_sleep): Revert previous change to declaration.
2003-11-10 21:28:02 +00:00
Corinna Vinschen 07ff303782 * winsup.h (low_priority_sleep): Fix declaration to avoid linker
warning.
2003-11-10 21:17:53 +00:00
Thomas Pfaff 73e36316cc * thread.cc (__reent_t::init_clib): Set thread local clib
__sdidinit var appropriately.
2003-11-10 19:44:53 +00:00
Corinna Vinschen 1db928422e * syscalls.cc (ftruncate64): Log length as long long.
(logout): Erase ut_host.  Don't write wtmp entry.  Return 1 only
	if matching utmp entry has been found, 0 otherwise.
2003-11-08 16:38:34 +00:00
Corinna Vinschen 8e68687d2a * external.cc (cygwin_internal): Add CW_GET_UID_FROM_SID and
CW_GET_GID_FROM_SID handling.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/cygwin.h (cygwin_getinfo_types): Add
	CW_GET_UID_FROM_SID and CW_GET_GID_FROM_SID.
2003-11-08 09:48:48 +00:00
Corinna Vinschen 0a5ea9471b * cygpath.cc (main): Allow multiple pathnames on command line. 2003-11-07 18:30:35 +00:00
Christopher Faylor 182d0e28a7 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Reorganize to handle
freeing of memory on error condition.
2003-11-07 18:22:26 +00:00
Christopher Faylor ef4d65ba95 * cygthread.cc (cygthread::freerange): Set inuse count. Avoid setting ev from
h as h would be NULL at this point.
(cygthread::operator new): Issue debugging info when overflowing the thread
pool.
(cygthread::cygthread): Set ev from h here after h has been initialized.
2003-11-07 18:21:05 +00:00
Corinna Vinschen 03c8f22f77 * Missing patch to cygwin.din. 2003-11-06 21:36:17 +00:00
Corinna Vinschen 3e68e19f05 * bsdlib.cc (_vwarnx): New function.
(vwarn): Ditto.
	(vwarnx): Ditto.
	(warn): Ditto.
	(warnx): Ditto.
	(verr): Ditto.
	(verrx): Ditto.
	(err): Ditto.
	(errx): Ditto.
	* cygwin.din: Export above functions.
	* include/err.h: New file.
	* include/cygwin/version.h: Bump API minor number.
2003-11-06 21:31:24 +00:00
Corinna Vinschen 6ef3b76be2 * syscalls.cc (getshmlba): New function.
* external.cc (cygwin_internal): Add CW_GET_SHMLBA handling.
	* mmap.cc (mmap64): Call getshmlba to evaluate granularity.
	* winsup.h (getshmlba): Add declaration.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/cygwin.h (cygwin_getinfo_types): Add CW_GET_SHMLBA.
2003-11-06 14:33:16 +00:00
Christopher Faylor fad5aef860 * winsup.h: Declare access_worker. 2003-11-06 13:58:45 +00:00
Corinna Vinschen 80ab7cb41f * include/cygwin/types.h: Fix preprocessor guards for vm_offset_t and
vm_size_t.  Add typedef for vm_object_t.
2003-11-06 10:46:49 +00:00
Christopher Faylor d417aec908 * fhandler_disk_file.cc (fhandler_disk_file::opendir): Detect attempt to open a
directory which lacks read privileges.
2003-11-05 16:53:55 +00:00
David Starks-Browning 1be28abadf Entry "Where is the su command?" -> "Why doesn't su work?" 2003-11-04 22:05:31 +00:00
Corinna Vinschen bcd06214e1 * external.cc (cygwin_internal): Add CW_GET_POSIX_SECURITY_ATTRIBUTE
handling.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/cygwin.h (cygwin_getinfo_types): Add
	CW_GET_POSIX_SECURITY_ATTRIBUTE.

	* exceptions.cc (init_global_security): Move from here...
	* sec_helper.cc (init_global_security): ...to here.
2003-11-04 15:48:19 +00:00
Christopher Faylor c35391d0d2 * net.cc (dup_ent): Use IsBadStringPtr for alignment checks. Don't use a known
bad pointer.
2003-11-04 13:15:47 +00:00
Corinna Vinschen 02bd05e386 * passwd.c (PrintPW): Turn around meaning printed for "Password not
required" option to be in line with Windows meaning.
	(main): Use more appropriate 1008 option when calling
	NetUserSetInfo to change flag values.
2003-11-04 10:54:47 +00:00
Corinna Vinschen 1f4e5e1571 * passwd.c (UF_LOCKOUT): Remove (defined in lmaccess.h).
(version): Bump version number to 1.5.
	(longopts): Add -c, -C, -e, -E, -p, -P options.
	(opts): Ditto.
	(PrintPW): Print values of UF_PASSWD_CANT_CHANGE and
	UF_DONT_EXPIRE_PASSWD flags. Slightly reformat output. Don't suppress
	correct system password settings just because the account has admin
	privileges.
	(usage): Define as "noreturn" function. Restructure and rephrase
	output. Accomodate new options.
	(print_version): Fix copyright dates.
	(main): Accomodate new options for setting UF_PASSWD_CANT_CHANGE,
	UF_DONT_EXPIRE_PASSWD and UF_PASSWD_NOTREQD settings.
2003-11-04 10:30:35 +00:00
Corinna Vinschen dff017b292 * net.cc (dup_ent): Move Win 95 misalignment recogition before
trying to evaluate string length.
2003-11-03 21:43:32 +00:00
Thomas Pfaff f796413184 * thread.cc (pthread::thread_init_wrapper): Initialize exception handling. 2003-10-31 20:47:14 +00:00
Thomas Pfaff c6e0f665bc Rename pthread::running to pthread::valid throughout.
* thread.h: (pthread::suspend_all_except_self): New static method.
(pthread::resume_all): Ditto.
(pthread::suspend_except_self): New method.
(pthread::resume): Ditto.
* thread.cc (pthread::suspend_except_self): Implement.
(pthread::resume): Ditto.
2003-10-31 20:42:56 +00:00
Corinna Vinschen d3f6bd13cb * include/stdint.h: Prevent signed->unsigned conversion for 32 and
64 bit min value constants.
2003-10-29 08:43:10 +00:00
Christopher Faylor 7825ed016f * path.cc (dot_special_chars): New global variable.
(special_name): Make files ending in "." special.
(fnunmunge): Allow encoded ".".
(mount_item::fnmunge): Handle trailing ".".
2003-10-29 01:15:12 +00:00
Christopher Faylor a4666b3d1b * include/stdint.h: Duplicate below effort for rest of *64_*. 2003-10-28 16:03:52 +00:00
Christopher Faylor 61c4ca410f * include/stdint.h: Correctly define INT64_MAX. 2003-10-28 15:13:06 +00:00
Danny Smith b19cda7bab * include/math.h: Guard ISO C99 additions with __cplusplus
not __GLIBCPP__.
2003-10-27 23:51:37 +00:00
Thomas Pfaff 7cba834bf2 * thread.h (fast_mutex::init): Initialize lock_counter. 2003-10-27 21:12:42 +00:00
Corinna Vinschen 56a4ceac3d * Makefile.in (OBSOLETE_FUNCTION): Add tmpfile.
(NEW_FUNCTIONS): Add _tmpfile64 -> tmpfile translation.
	* cygwin.din: Export _tmpfile64
	* include/cygwin/version.h: Bump api minor number.
2003-10-27 13:06:56 +00:00
Corinna Vinschen 072339664d * cygwin.din: Add sem_close, sem_getvalue, sem_open and sem_timedwait.
* pthread.cc (+mangle_sem_name): New function.
	(sem_open): Ditto.
	(sem_close: Ditto.
	(sem_timedwait): Ditto.
	(sem_getvalue): Ditto.
	* thread.cc (semaphore::semaphore): Rearrange member initialization.
	Use appropriate security attribute for process shared semaphores.
	(semaphore::semaphore): New constructor for named semaphores.
	(semaphore::~semaphore): Care for semaphore name.
	(semaphore::_post): Accomodate failing ReleaseSemaphore. Use value
	returned by ReleaseSemaphore vor currentvalue.
	(semaphore::_getvalue): New method.
	(semaphore::_timedwait): Ditto.
	(semaphore::_fixup_after_fork): Rearrange. Don't fail for process
	shared semaphores.
	(semaphore::open): New method.
	(semaphore::timedwait): Ditto.
	(semaphore::post): Fix return value.  Set errno appropriately.
	(semaphore::getvalue): New method.
	* thread.h (class semaphore): Add prototypes for open, getvalue,
	timedwait, _getvalue, _timedwait.  Add prototypes for new constructor.
	Add name member.
	* include/semaphore.h: Add prototypes for sem_open, sem_close,
	sem_timedwait and sem_getvalue.
	include/cygwin/version.h: Bump API minor number.
2003-10-27 11:48:29 +00:00
Corinna Vinschen d845665e0f * miscfunc.cc (__check_invalid_read_ptr): New function.
* winsup.h: Declare.
2003-10-27 08:28:37 +00:00
Corinna Vinschen db30fe125f * security.h (cygpsid::debug_print): Avoid compiler warnings. 2003-10-26 10:58:11 +00:00
Christopher Faylor 13d5cc4020 Remove file that was supposed to have disappeared a month ago. 2003-10-26 01:09:06 +00:00
Corinna Vinschen 504678827a * path.cc (normalize_posix_path): Test runs of more than two
dots for being a run of only dots.  Let it pass if not.
2003-10-25 16:12:45 +00:00
Corinna Vinschen 89256ff149 * fhandler.cc (fhandler_base::ioctl): Handle FIONBIO. 2003-10-25 12:32:56 +00:00
Thomas Pfaff 28194e813e Rename native_mutex to fast_mutex throughout.
Rename pthread_key::save_key_to_buffer to
pthread_key::_fixup_before_fork throughout.
Rename pthread_key::recreate_key_from_buffer to
pthread_key::_fixup_after_fork throughout.

* thread.cc (native_mutex::init): Remove.
(native_mutex::lock): Ditto.
(native_mutex::unlock): Ditto.
(pthread::push_cleanup_handler): InterlockedExchangePointer
is not needed here.
(pthread_rwlock::pthread_rwlock): Initialize readers list mutex.
(pthread_rwlock::add_reader): Add reader via List_insert.
(pthread_rwlock::lookup_reader): Lock list while walking through.
(pthread_cond::init): Locking the init mutex is now void.
(pthread_rwlock::init): Ditto.
(pthread_mutex::init): Ditto.
* thread.h: Include security.h.
(fast_mutex): New class. Replacement for native_mutex.
(List_insert): New template function.
(List_remove): Ditto.
(List::List): Initialize synchronising mutex.
(List::fixup_after_fork): New method.
(List::insert): Add node via List_insert.
(List::remove): Remove node via List_remove.
(List::pop): Remove.
(List::for_each): Lock list while walking through.
(List::mx_init): New method.
(pthread_mutex::fixup_after_fork): Fixup mutex list after fork.
(pthread::fixup_after_fork): Ditto.
(pthread_conds::fixup_after_fork): Ditto.
(pthread_rwlock::fixup_after_fork): Ditto.
(semaphore::fixup_after_fork): Ditto.
(pthread_rwlock::readers_mx): New member.
2003-10-24 19:34:47 +00:00
Corinna Vinschen 2b7dcf79ae * fhandler.cc (fhandler_base::fcntl): Don't clobber O_APPEND when
both O_NONBLOCK/O_NDELAY are set for F_SETFL.
2003-10-24 12:11:20 +00:00
Corinna Vinschen 0b4274f58b * path.cc (win32_device_name): Fix comment. 2003-10-24 08:13:15 +00:00
Christopher Faylor e64a50ed4e * fhandler_tty.cc (fhandler_tty_slave::ioctl): Properly set return value in
FIONBIO case.
2003-10-24 01:13:22 +00:00
Corinna Vinschen f49c14a197 * fhandler_proc.cc (format_proc_partitions): Use new device code
to get major and minor device numbers.  Fix size evaluation.
2003-10-23 08:54:00 +00:00
Corinna Vinschen 5ec9ea21a3 * external.cc (cygwin_internal): Add CW_GET_ERRNO_FROM_WINERROR
handling.
	* include/cygwin/version.h: Bump API minor number.
	* include/sys/cygwin.h (cygwin_getinfo_types): Add
	CW_GET_ERRNO_FROM_WINERROR.
2003-10-22 20:32:20 +00:00
Corinna Vinschen e217832c4c * Makefile.in: Add $(LIBSERVER) rule.
* cygserver.h: Moved from include/cygwin to here.
	* cygserver_ipc.h: Moved from ../cygserver to here.
	* cygserver_shm.h: Ditto.
	* cygwin.din: Add shmat, shmctl, shmdt and shmget.
	* fhandler_tty.cc (fhandler_tty_slave::open): Don't warn about handle
	dup'ing if not build with USE_SERVER.
	* shm.cc: Include cygerrno.h unconditionally.
	(shmat): Set errno to ENOSYS and return -1 if not build with
	USE_SERVER.
	(shmctl): Ditto.
	(shmdt): Ditto.
	(shmget): Ditto.
	* woutsup.h: Remove.
	* include/cygwin/cygserver_process.h: Moved to ../cygserver directory.
	* include/cygwin/cygserver_transport.h: Ditto.
	* include/cygwin/cygserver_transport_pipes.h: Ditto.
	* include/cygwin/cygserver_transport_sockets.h: Ditto.
	* include/cygwin/version.h: Bump API minor number.
2003-10-22 10:07:59 +00:00
Corinna Vinschen 567970786e Accomodate moving cygserver header files from cygwin/include/cygwin
to here and cygwin dir.
	* Makefile.in (EXEEXT): Drop as unused.
	(EXEEXT_FOR_BUILD): Ditto.
	(all): Don't build libcygserver.a.
	* cygserver_process.h: Moved from cygwin/include/cygwin to here.
	* cygserver_transport.h: Ditto.
	* cygserver_transport_pipes.h: Ditto.
	* cygserver_transport_sockets.h: Ditto.
	* ipc.h: Moved to ../cygwin and renamed to cygserver_ipc.h.
	* shm.h: Moved to ../cygwin and renamed to cygserver_shm.h.
2003-10-22 10:04:11 +00:00
Danny Smith 79be64037c * include/_mingw.h: Define __attribute__((x)) to nothing
if not __GNUC__.
2003-10-21 09:50:47 +00:00
Danny Smith 3c7a7a5fca Add ISO C99 complex support for doubles.
* include/complex.h: New file.
	* mingwex/complex: New directory.
	* mingwex/complex/cabs.c: New file.
	* mingwex/complex/cacos.c: New file.
	* mingwex/complex/cacosh.c: New file.
	* mingwex/complex/casin.c: New file.
	* mingwex/complex/casinh.c: New file.
	* mingwex/complex/catan.c: New file.
	* mingwex/complex/catanh.c: New file.
	* mingwex/complex/ccos.c: New file.
	* mingwex/complex/ccosh.c: New file.
	* mingwex/complex/cexp.c: New file.
	* mingwex/complex/cimag.c: New file.
	* mingwex/complex/clog.c: New file.
	* mingwex/complex/cpow.c: New file.
	* mingwex/complex/cproj.c: New file.
	* mingwex/complex/creal.c: New file.
	* mingwex/complex/csin.c: New file.
	* mingwex/complex/csinh.c: New file.
	* mingwex/complex/csqrt.c: New file.
	* mingwex/complex/ctan.c: New file.
	* mingwex/complex/ctanh.c: New file.
	* mingwex/Makefile.in (COMPLEX_DISTFILES): New list of
	files.
	(dist): Use it.
	(COMPLEX_OBJS): New list of objects.
	(LIB_OBJS): Include it in the library.
2003-10-21 09:43:22 +00:00
Danny Smith 6de52354eb * include/math.h (cabs): Remove non-ISO prototype. 2003-10-21 09:14:45 +00:00
Danny Smith 359e09e7fd * mingwex/math/cephes_mconf.h (NAN, NANF, NANL):
Use GCC __builtin's if available.
	(INFINITY, INFINITYF, INFINITYL): Likewise.
2003-10-21 09:10:51 +00:00
Danny Smith 672126d4f1 * mingwex/math/s_erf.c (erf): Set errno to ERANGE if
beyond approximation limit.
	* mingwex/math/sf_erf.c (erff): Likewise.
2003-10-21 09:05:24 +00:00
Danny Smith f25e45973d * include/stdio.h (_filbuf): Add prototype.
(_flsbuf): Add prototype.
	(getc): Add inline version.
	(putc): Likewise.
	(getchar): Likewise.
	(putchar): Likewise.
2003-10-17 21:43:31 +00:00
Christopher Faylor ce17145aa8 revert accidental checkin 2003-10-17 17:20:06 +00:00
Christopher Faylor fa10472e4a * cygcheck.cc (pretty_id): Don't exec if `id' program is not found. 2003-10-17 17:19:31 +00:00
Dimitri Papadopoulos 5320b93f4e Oooops... 2003-10-17 10:37:44 +00:00
Pierre Humblet 30f515c54f *** empty log message *** 2003-10-16 23:28:31 +00:00
Pierre Humblet 9808b5c420 2003-10-16 Pierre Humblet <pierre.humblet@ieee.org>
* syscalls.cc (seteuid32): Always construct a default DACL including
	the new sid, Admins and SYSTEM and copy it to the new thread token.
	* security.cc (create_token): Use a NULL default DACL in NtCreateToken.
2003-10-16 23:20:41 +00:00
Corinna Vinschen abfc9c412c * dcrt0.cc: Remove local variable alternate_charset_active.
* fhandler.h: Add variable alternate_charset_active, functions
	str_to_con, con_to_str to dev_console structure.
	* fhandler_console.cc (con_to_str): Move function into dev_console
	class.
	(str_to_con): Ditto.
	(fhandler_console::read): Call con_to_str on dev_state.
	(fhandler_console::write_normal): Call str_to_con on dev_state.
	(fhandler_console::char_command): Change active_charset_active
	assignment to be on dev_state.
	* winsup.h: Remove global external variable alternate_charset_active.
2003-10-16 14:08:28 +00:00
Corinna Vinschen ce34c904cc * fhandler_console.cc (char_command): Add escape sequence for codepage
ansi <-> oem switching for ncurses frame drawing capabilities.
	* dcrt0.cc: Add local variable alternate_charset_active.
	* winsup.h: Add global external variable alternate_charset_active.
2003-10-15 08:23:26 +00:00
Corinna Vinschen db3137ccb5 * exceptions.cc (ctrl_c_handler): Don't send SIGHUP on
CTRL_LOGOFF_EVENT to processes running in invisible Windows Stations.
	* window.cc (has_visible_window_station): New function.
	* winsup.h: Add declaration for has_visible_window_station.
2003-10-14 09:21:55 +00:00
Dimitri Papadopoulos 36ef425c19 * include/windows.h (CopyCursor): Although MSDN pretends this is
a function to be imported from user32.lib, it's actually a macro.
	From the Delphi FAQ:
		Question:
		Where is the Windows API function CopyCursor defined in
		32-Bit versions of Delphi and C++ Builder?
		Answer:
		While the call is documented in the Win32 help file, the
		function is simply mapped to the Windows API function
		CopyIcon(). Note that the 32 bit version of CopyIcon
		does not take a hInstance parameter.
2003-10-13 06:02:06 +00:00
Danny Smith 29598fc7e0 2003-10-13 Steven Edwards <Steven_Ed4153@yahoo.com>
* include/winnt.h (CONTAINING_RECORD): Add macro.
2003-10-13 05:22:30 +00:00
Danny Smith 851217a605 * include/winnt.h: (FILE_SUPERSEDED, FILE_OPENED, FILE_CREATED,
FILE_OVERWRITTEN, FILE_EXISTS, FILE_DOES_NOT_EXIST): remove
	defines.
2003-10-13 03:25:26 +00:00
Danny Smith 64c0532eb5 2003-10-13 Filip Navara <xnavara@volny.cz>
* include/commctrl.h: (DSA_*):Add prototypes, typedefs and
	defines for Dynamic Storage Arrays.
	(DPA_*): Likewise, for Dynamic Pointer Arrays.
	(FlatSB_*, InitializeFlatSB, InitializeFlatSB): Add prototypes
	and defines for Flat ScrollBars.
	(SetWindowSubclass, GetWindowSubclass, RemoveWindowSubclass,
	DefSubclassProc): Add prototypes for subclassing.
	(DrawShadowText) Add prototype.
`	(COMCTL32_VERSION): Define.
2003-10-13 02:46:36 +00:00
Danny Smith fad2aa1aad 2003-10-13 Martin Fuchs <Martin-Fuchs@gmx.net>
* include/shlobj.h (CFSTR_FILENAME, CFSTR_FILEDESCRIPTOR,
	CFSTR_FILENAMEMAP, CFSTR_SHELLURL): Correct UNICODE definitions.
2003-10-13 00:22:38 +00:00
Danny Smith 0c7a57ebc0 2003-10-13 Pierre Humblet <pierre.humblet@ieee.org>
* include/winnt.h (SM_REMOTESESSION): Add define.
	* include/winuser.h (SE_CREATE_GLOBAL_NAME): Ditto.
2003-10-12 23:38:57 +00:00
Danny Smith b3355c6592 * include/wincrypt (KP_IV, KP_SALT, KP_PADDING, KP_MODE,
KP_MODE_BITS, KP_PERMISSIONS, KP_ALGID, KP_BLOCKLEN): Remove
	duplicate definitions.
	(KP_X, KP_Y): Correct typos.
2003-10-12 23:34:13 +00:00
Manu B 986ee16a0c Dummy afxres header, richedit constants added 2003-10-11 08:00:38 +00:00
Christopher Faylor 7cf29f96e0 * fhandler_tty.cc (fhandler_tty_slave::open): Don't create a new window station
if one already exists.
2003-10-10 19:11:21 +00:00
Christopher Faylor 4a204f6625 * shared.cc (shared_info::initialize): Remove myself check since hMainProc
initialization will allow user initialization to work.
2003-10-10 19:07:08 +00:00
Earnie Boyd f3d0380417 * include/_mingw.h: Increment version to 3.2.
* Makefile.in: Ditto.
2003-10-10 18:25:10 +00:00
Christopher Faylor cca873af60 fix typo 2003-10-10 17:44:54 +00:00
Earnie Boyd 79b931ee81 * include/sys/types.h: Revert last change. 2003-10-10 15:09:55 +00:00
Earnie Boyd 92fda2d938 * include/sys/types.h (ssize_t): Correct the definition. 2003-10-10 11:49:36 +00:00
Corinna Vinschen a8e5f8c6c2 * include/sys/mman.h (MAP_FAILED): Define as void *. 2003-10-09 11:40:16 +00:00
Dimitri Papadopoulos 6ddad5e1dd * include/errorep.h: New file.
* lib/faultrep.def: New file.
2003-10-09 05:52:12 +00:00
Dimitri Papadopoulos 38f9123efd * include/winbase.h (AddVectoredExceptionHandler): Define if
_WIN32_WINNT >= 0x0500.

	* include/winnt.h (PVECTORED_EXCEPTION_HANDLER): Define if
	_WIN32_WINNT >= 0x0500.
2003-10-09 05:28:25 +00:00
Christopher Faylor ea4980efe1 * dcrt0.cc (hMainProc): Initialize to useful value for use when dll is
dynamically loaded.
(shared_info::initialize): Don't initialize user stuff if myself doesn't exit.
2003-10-08 21:40:33 +00:00
Corinna Vinschen 5df75951a5 * include/winbase.h (AddVectoredExceptionHandler): Only define if
_WIN32_WINNT >= 0x0501.
2003-10-08 15:58:58 +00:00
Corinna Vinschen 99439385c6 * syscalls.cc (unlink): Don't even try DELETE_ON_CLOSE technique on
systems not supporting it.
2003-10-08 09:17:08 +00:00
Dimitri Papadopoulos 56efe3a884 * include/winbase.h [_WIN32_WINNT >= 0x0500] (SetComputerNameEx[AW],
UnregisterWaitEx): Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0500]
	(AddVectoredExceptionHandler, RemoveVectoredExceptionHandler): Add
	or guard function. The MSDN says it is available on Windows XP and
	better, and then it says it is declared for _WIN32_WINNT >= 0x0500.
	Huh?

	* include/winbase.h [_WIN32_WINNT >= 0x0501] (AddRefActCtx,
	CreateActCtx[AW], SetFileShortName[AW], SetFileValidData,
	ZombifyActCtx, QueryActCtxW): Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(QUERY_ACTCTX_FLAG_USE_ACTIVE_ACTCTX,
	QUERY_ACTCTX_FLAG_ACTCTX_IS_HMODULE,
	QUERY_ACTCTX_FLAG_ACTCTX_IS_ADDRESS): Add constants.

	* include/winbase.h [_WIN32_WINNT >= 0x0502] (SetDllDirectory[AW],
	SetFirmwareEnvironmentVariable[AW]): Add functions.

	* include/winnt.h [_WIN32_WINNT >= 0x0500] (VER_BUILDNUMBER,
	VER_MAJORVERSION, VER_MINORVERSION, VER_PLATFORMID,
	VER_SERVICEPACKMAJOR, VER_SERVICEPACKMINOR, VER_SUITENAME,
	VER_PRODUCT_TYPE, VER_EQUAL, VER_GREATER, VER_GREATER_EQUAL,
	VER_LESS, VER_LESS_EQUAL, VER_AND, VER_OR): Add constants.

	* include/winnt.h [_WIN32_WINNT >= 0x0501]
	(PVECTORED_EXCEPTION_HANDLER): Add callback.

	* include/winnt.h [_WIN32_WINNT >= 0x0501]
	(ACTIVATION_CONTEXT_INFO_CLASS,
	ACTIVATION_CONTEXT_ASSEMBLY_DETAILED_INFORMATION,
	ACTIVATION_CONTEXT_DETAILED_INFORMATION,
	ACTIVATION_CONTEXT_QUERY_INDEX, ASSEMBLY_FILE_DETAILED_INFORMATION):
	Add structures.

	* lib/user32.def (AddRefActCtx, AddVectoredExceptionHandler,
	CreateActCtx[AW], SetComputerNameEx[AW], SetDllDirectory[AW],
	SetFileShortName[AW], SetFileValidData,
	SetFirmwareEnvironmentVariable[AW], UnregisterWaitEx,
	VerSetConditionMask, ZombifyActCtx, QueryActCtxW): Add functions.
2003-10-07 12:55:00 +00:00
Dimitri Papadopoulos 2df2984b40 * include/winbase.h (GetWriteWatch, IsSystemResumeAutomatic,
ResetWriteWatch): Add function.

	* include/winbase.h [_WIN32_WINNT >= 0x0500]
	(GetSystemWindowsDirectory[AW], ProcessIdToSessionId, ReplaceFile[AW]):
	Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(GetSystemWow64Directory[AW], HeapQueryInformation,
	HeapSetInformation, InitializeSListHead, InterlockedFlushSList,
	InterlockedPopEntrySList, InterlockedPushEntrySList, IsProcessInJob,
	IsWow64Process, QueryMemoryResourceNotification, ReleaseActCtx,
	RemoveVectoredExceptionHandler): Add functions.

	* include/winnt.h [_WIN32_WINNT >= 0x0501] (HEAP_INFORMATION_CLASS):
	Add enumeration.

	* include/winbase.h [_WIN32_WINNT >= 0x0502] (GetThreadIOPendingFlag):
	Add function.

	* include/winbase.h [_WIN32_WINNT >= 0x0510] (RestoreLastError):
	Add function. The MSDN Magazine of June 2003 reads:
		RestoreLastError is an enigma. It's code is identical to
		SetLastError. It's unclear to me why it was made into a
		separate API.

	* lib/user32.def (GetSystemWindowsDirectory[AW],
	GetSystemWow64Directory[AW], GetThreadIOPendingFlag,
	HeapQueryInformation, HeapSetInformation, InitializeSListHead,
	InterlockedFlushSList, InterlockedPopEntrySList,
	InterlockedPushEntrySList, IsSystemResumeAutomatic, IsWow64Process,
	ProcessIdToSessionId, QueryMemoryResourceNotification, ReleaseActCtx,
	RemoveVectoredExceptionHandler, ReplaceFile[AW], ResetWriteWatch,
	RestoreLastError): Add functions.
2003-10-07 10:14:31 +00:00
Dimitri Papadopoulos f9a322ebf7 * include/winbase.h [_WIN32_WINNT >= 0x0500] (GetComputerNameEx[AW],
GetProcessIoCounters): Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0500] (COMPUTER_NAME_FORMAT):
	Move around, needed by GetComputerNameEx.

	* include/winbase.h [_WIN32_WINNT >= 0x0501] (FindActCtxSectionGuid,
	FindActCtxSectionString[AW], GetCurrentActCtx, GetNativeSystemInfo):
	Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(ACTCTX_SECTION_KEYED_DATA): Add structure.

	* include/winbase.h [_WIN32_WINNT >= 0x0502] (GetDllDirectory[AW],
	GetFirmwareEnvironmentVariable[AW], GetProcessHandleCount,
	GetProcessId, GetSystemRegistryQuota): Add functions, available on
	Windows XP SP1 and better.

	* include/winnt.h [_WIN32_WINNT >= 0x0501]
	(ACTIVATION_CONTEXT_SECTION_ASSEMBLY_INFORMATION,
	ACTIVATION_CONTEXT_SECTION_DLL_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_WINDOW_CLASS_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_COM_SERVER_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_COM_INTERFACE_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_COM_TYPE_LIBRARY_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_COM_PROGID_REDIRECTION,
	ACTIVATION_CONTEXT_SECTION_CLR_SURROGATES): Add constants.

	* lib/user32.def (FindActCtxSectionGuid, FindActCtxSectionString[AW],
	GetComputerNameEx[AW], GetCurrentActCtx, GetDllDirectory[AW],
	GetFirmwareEnvironmentVariable[AW], GetModuleHandleEx[AW],
	GetNativeSystemInfo, GetProcessHandleCount, GetProcessIoCounters):
	Add functions.
2003-10-07 08:47:06 +00:00
Dimitri Papadopoulos d0ede583ee * include/winbase.h [_WIN32_WINNT >= 0x0501]
(CheckRemoteDebuggerPresent, DebugActiveProcessStop, DebugBreakProcess,
	DebugSetProcessKillOnExit): Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0500] (DeleteTimerQueue,
	DeleteTimerQueueEx, DeleteTimerQueueTimer,
	DnsHostnameToComputerName[AW]): Add functions.

	* lib/user32.def (CheckRemoteDebuggerPresent, DebugActiveProcessStop,
	DebugBreakProcess, DebugSetProcessKillOnExit, DeleteTimerQueueEx,
	DeleteTimerQueueTimer, DnsHostnameToComputerName[AW]): Add functions.
2003-10-07 07:14:53 +00:00
Dimitri Papadopoulos b2608a4378 * include/winbase.h (GetVolumePathNamesForVolumeName): Available
on Windows XP and later.
2003-10-07 05:54:53 +00:00
Dimitri Papadopoulos 85c50f7194 * include/commctrl.h (TreeView_Select): Returns BOOL. 2003-10-07 05:41:46 +00:00
Dimitri Papadopoulos d645cc8736 * include/winbase.h (CancelDeviceWakeupRequest): Add function.
* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(CreateMemoryResourceNotification, DeactivateActCtx): Add functions.

	* include/winbase.h [_WIN32_WINNT >= 0x0500] (CreateTimerQueue,
	CreateTimerQueueTimer): Add function.

	* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(MEMORY_RESOURCE_NOTIFICATION_TYPE): Add enumeration.

	* include/winbase.h [_WIN32_WINNT >= 0x0501]
	(DEACTIVATE_ACTCTX_FLAG_FORCE_EARLY_DEACTIVATION): Add constant.

	* include/winnt.h (WT_*): Add constants.

	* lib/user32.def (CancelDeviceWakeupRequest,
	CreateMemoryResourceNotification, CreateTimerQueueTimer,
	DeactivateActCtx): Add functions.
2003-10-06 12:33:32 +00:00
Dimitri Papadopoulos 16640527a7 * include/winbase.h [_WIN32_WINNT >= 0x0400] (ConvertFiberToThread):
Add function. Sometimes I don't understand MSDN. This function is
	available on Windows XP and Server 2003, but the SDK is supposed to
	make it available when _WIN32_WINNT >= 0x0400, or so says the MSDN.
	Mmmh...

	* include/winbase.h [_WIN32_WINNT >= 0x0400] (CreateFiberEx):
	Guard function. Same remark as above.

	* lib/user32.def (ConvertFiberToThread, CreateFiberEx):
	Add functions.
2003-10-06 10:00:31 +00:00
Dimitri Papadopoulos a61556238e * include/winbase.h [_WIN32_WINNT >= 0x0501] (ACTCTX_FLAG_*):
Add constants.

	* include/winbase.h [_WIN32_WINNT >= 0x0501] (ACTCTX[AW]): Add
	structures.

	* include/winbase.h [_WIN32_WINNT >= 0x0501] (ActivateActCtx): Add
	function. MSDN says the first argument is HACTCTX but I'm not sure
	where such a specialized handle is defined, so use HANDLE instead.

	* include/winbase.h [_WIN32_WINNT >= 0x0501] (AttachConsole,
	CheckNameLegalDOS8Dot3[AW]): Add functions.

	* lib/user32.def (ActivateActCtx, AttachConsole,
	CheckNameLegalDOS8Dot3[AW]): Add functions.

	* lib/user32.def (AddLocalAlternateComputerName[AW]): Add functions.
	Unfortunately I don't know which header to put the declarations in.
2003-10-06 09:45:59 +00:00
Dimitri Papadopoulos 928bc4d571 * include/winnls.h (CTRY_KYRGYZSTAN, CTRY_MALDIVES, CTRY_MONGOLIA):
Add constants.

	* include/winnls.h (NLS_FUNCTION, SYSGEOCLASS, SYSGEOTYPE): Add
	constants for National Language Support.

	* include/winnls.h (NLSVERSIONINFO): Add structure for National
	Language Support.

	* include/winnls.h (GEO_ENUMPROC): Add callback for National
	Language Support.

	* include/winnls.h (EnumSystemGeoID, GetCalendarInfo[AW],
	GetGeoInfo[AW], GetUserGeoID, SetCalendarInfo[AW], SetUserGeoID):
	Add functions.

	* include/winnls.h (IsNLSDefinedString, GetNLSVersion): Add
	functions. Strange... I am unable to find which library contains
	these functions. Can't find anything with pexports. Any clue?

	* lib/user32.def (EnumSystemGeoID, GetGeoInfo[AW], GetUserGeoID,
	SetUserGeoID): Add functions.
2003-10-06 09:02:04 +00:00
Dimitri Papadopoulos 971a485f99 * include/winnt.h (LANG_KYRGYZ, LANG_MONGOLIAN, LANG_GALICIAN,
LANG_SYRIAC, LANG_INVARIANT, SUBLANG_KASHMIRI_SASIA): Add constants.

	* include/winnt.h (SUBLANG_AZERI_LATIN, SUBLANG_AZERI_CYRILLIC,
	SUBLANG_ENGLISH_ZIMBABWE, SUBLANG_ENGLISH_PHILIPPINES): Fix wrong
	value for constants.
2003-10-06 06:47:41 +00:00
Dimitri Papadopoulos 083817a45b * include/wincrypt.h (KP_SCHANNEL_ALG): Add constant. Specifying
the algorithms.
2003-10-03 12:14:13 +00:00
Dimitri Papadopoulos f9cb5fcec4 * include/wincrypt.h (SCHANNEL_MAC_KEY, SCHANNEL_ENC_KEY,
INTERNATIONAL_USAGE): Add constants. Specifying the Algorithms
2003-10-03 12:11:04 +00:00
Dimitri Papadopoulos 37b6c4adc5 * include/wincrypt.h (CRYPT_FLAGS_*): Add constants. Protocol flags. 2003-10-03 12:06:05 +00:00
Dimitri Papadopoulos 8e14117566 * include/wincrypt.h (KP_*): Add constants. Needed by
CryptSetKeyParam() and other functions.
2003-10-03 12:04:02 +00:00
Dimitri Papadopoulos b9c5ea438c * include/winuser.h [_WIN32_WINNT >= 0x0501] (EVENT_*, CONSOLE_*):
Add constants, related to Console Accessibility.
2003-10-03 11:38:07 +00:00
Dimitri Papadopoulos 4fd4d446d6 * include/winuser.h [WINVER >= 0x0500] (EVENT_MAX): Ooops...
wrong value for constant.
2003-10-03 10:29:16 +00:00
Dimitri Papadopoulos ba4ad171e6 * include/winuser.h [WINVER >= 0x0500] (EVENT_*): Add constants.
* include/uxtheme.h: Cleanup.
	* include/tmschema.h: Cleanup.
2003-10-03 10:27:27 +00:00
Danny Smith e1ce6d5f2a * include/stdio.h (_filbuf): Add prototype.
(_flsbuf): Add prototype.
	(getc): Add inline version.
	(putc): Likewise.
	(getchar): Likewise.
	(putchar): Likewise.
2003-10-03 10:16:53 +00:00
Danny Smith c536f54ada * mingwex/dirent.c (_treaddir): Reset errno to 0 if end
of directory.
2003-10-02 21:29:51 +00:00
Christopher Faylor 8923806299 * dcrt0.cc (dll_crt0_1): Call newlib __sinit routine to ensure that stdio
buffers are initialized to avoid thread initialization races.
2003-10-02 04:46:59 +00:00
Christopher Faylor 6cb54a4cee * path.cc (win32_device_name): Only fill out destination buffer when it's
really a device.
2003-10-02 03:50:10 +00:00
Luke Dunstan db0d31d13e 2003-10-02 Luke Dunstan <infidel@users.sourceforge.net>
* include/winspool.h (GetDefaultPrinter[AW]): Add functions.
	* lib/winspool.def (GetDefaultPrinter[AW]): Add stubs.
2003-10-02 02:39:43 +00:00
Danny Smith 334117a940 * include/winnt.h (INVALID_FILE_ATTRIBUTES): Fix define. 2003-10-01 21:40:43 +00:00
Christopher Faylor 0e1ba88882 * Makefile.in: Add YA method for generating devices.cc.
* child_info.h: YA update of another magic number.
* gendevices: New file.
* devices.in: New file.
* devices.cc: Regenerate.
* devices.shilka: Remove.
* devices.h: Correctly define device pointers.
(device): Remove now obsolete fields.
(device::native): Renamed from device::fmt.
* dtable.cc (build_fh_dev): Simplify in light of new unit parsing scheme.
(build_fh_pc): Ditto.
* path.cc (win32_device_name): Ditto.
* fhandler.h (fhandler_base::get_native_name): Reflect renaming of fmt to
native.
* fhandler_tty.cc (fhandler_tty_mster::init): Initialize slave device prior to
reporting unit.
2003-10-01 12:36:39 +00:00
Corinna Vinschen 883c5345d4 * fhandler.cc (fhandler_base::fstat): Drop FH_FLOPPY case. 2003-09-30 21:46:08 +00:00
Corinna Vinschen a4b25e31ca * fhandler.h (class fhandler_dev_raw): Add method fstat.
* fhandler_raw.cc (fhandler_dev_raw::fstat): New method.

	Add missing ChangeLog for previous patch.
2003-09-30 21:43:40 +00:00
Corinna Vinschen 7f7eda0780 * devices.h (enum fh_devices): Remove DEV_RAWDRIVE_MAJOR and
FH_RAWDRIVE.
	* devices.shilka (dev_rawdrive_storage): Remove.
	(unit_devices): Remove pointer to dev_rawdrive_storage.
	(uniq_devices): Remove rawdrive entry.
	* dtable.cc (build_fh_pc): Remove DEV_RAWDRIVE_MAJOR case.
	* path.cc (win32_device_name): ditto.
2003-09-30 21:03:57 +00:00
Danny Smith fe5fb62c09 Remove conflict indicator from ChangeLog 2003-09-30 07:53:10 +00:00
Danny Smith 4d36c543ea * include/winuser.h (BSF_*, BSM_*): Sync constants defined in
both winuser.h and dbt.h.
	* include/dbt.h (BSF_*, BSM_*): Likewise.

	* include/winuser.h (struct tagRAWINPUT): Remove
	_ANONYMOUS_UNION tag from named union.
	(struct tagRAWMOUSE): Add _ANONYMOUS_STRUCT to nameless struct.
2003-09-30 07:51:26 +00:00
Dimitri Papadopoulos 684f94e305 * include/dhcpcsvc.h: New file.
Note that MSDN is confused about whether it should start constant
	and structure names with DHCPCAPI or DHCPAPI. It's using both but
	experience suggests it's DHCPCAPI with `C'.

	* lib/dhcpcsvc.def: New file.
2003-09-30 07:40:46 +00:00
Dimitri Papadopoulos e7e4107e39 * include/winuser.h [_WIN32_WINNT >= 0x0501] (RIM_INPUT,
RIM_INPUTSINK): Add constants, for use by WM_INPUT notification.

	* include/winuser.h [_WIN32_WINNT >= 0x0501] (RIDEV_REMOVE,
	RIDEV_EXCLUDE, RIDEV_PAGEONLY, RIDEV_NOLEGACY, RIDEV_INPUTSINK,
	RIDEV_CAPTUREMOUSE, RIDEV_NOHOTKEYS, RIDEV_APPKEYS): Add constants,
	for use in RAWINPUTDEVICE.

	* include/winuser.h [_WIN32_WINNT >= 0x0501]
	(GetRawInputDeviceInfo[AW]): Ooops... there are
	ANSI/Unicode versions of this function.

	* lib/user32.def (GetRawInputDeviceInfo[AW]): Ooops... there
	are ANSI/Unicode versions of this function.
2003-09-30 06:57:46 +00:00
Corinna Vinschen d950ca774f * syslog.cc (vsyslog): Print debug message if ReportEventA fails. 2003-09-29 12:31:22 +00:00
Danny Smith 3c3b1816d8 * include/stdlib.h: Guard non-ISO functions with
!__STRICT_ANSI__, throughout.
2003-09-29 09:16:23 +00:00
Dimitri Papadopoulos 37048d3df7 * include/winuser.h [_WIN32_WINNT >= 0x0501] (RIM_TYPEMOUSE,
RIM_TYPEKEYBOARD, RIM_TYPEHID, MOUSE_MOVE_RELATIVE,
	MOUSE_MOVE_ABSOLUTE, MOUSE_VIRTUAL_DESKTOP,
	MOUSE_ATTRIBUTES_CHANGED, RI_MOUSE_LEFT_BUTTON_DOWN,
	RI_MOUSE_LEFT_BUTTON_UP, RI_MOUSE_RIGHT_BUTTON_DOWN,
	RI_MOUSE_RIGHT_BUTTON_UP, RI_MOUSE_MIDDLE_BUTTON_DOWN,
	RI_MOUSE_MIDDLE_BUTTON_UP, RI_MOUSE_BUTTON_1_DOWNT_BUTTON_DOWN,
	RI_MOUSE_BUTTON_1_UP, RI_MOUSE_BUTTON_2_DOWNHT_BUTTON_DOWN,
	RI_MOUSE_BUTTON_2_UP, RI_MOUSE_BUTTON_3_DOWNDLE_BUTTON_DOWN,
	RI_MOUSE_BUTTON_3_UP, RI_MOUSE_BUTTON_4_DOWN,
	RI_MOUSE_BUTTON_4_UP, RI_MOUSE_BUTTON_5_DOWN,
	RI_MOUSE_BUTTON_5_UP, RI_MOUSE_WHEEL, KEYBOARD_OVERRUN_MAKE_CODE,
	RI_KEY_MAKE, RI_KEY_BREAK, RI_KEY_E0, RI_KEY_E1,
	RI_KEY_TERMSRV_SET_LED, RI_KEY_TERMSRV_SHADOW, RID_INPUT,
	RID_HEADER, RIDI_PREPARSEDDATA, RIDI_DEVICENAME,
	RIDI_DEVICEINFO): Add constants.

	* include/winuser.h [_WIN32_WINNT >= 0x0501] (RAWINPUTHEADER,
	RAWMOUSE, RAWKEYBOARD, RAWHID, RAWINPUT, RAWINPUTDEVICE,
	RAWINPUTDEVICELIST): Add structures.

	* include/winuser.h [_WIN32_WINNT >= 0x0501] (DefRawInputProc,
	GetRawInputBuffer, GetRawInputData, GetRawInputDeviceInfo,
	GetRawInputDeviceList, GetRegisteredRawInputDevices): Add functions.

	* lib/user32.def (DefRawInputProc, GetRawInputBuffer,
	GetRawInputData, GetRawInputDeviceInfo, GetRawInputDeviceList,
	GetRegisteredRawInputDevices): Add functions.
2003-09-29 08:54:50 +00:00
Christopher Faylor e6ba835513 * sigproc.cc (proc_subproc): Restrict permissions on ppid_handle.
* devices.shilka (device::parse): Restore check for tty in unit handling, but
without the previous typo.
* devices.cc: Regenerate.
* devices.h (DEV_CYGDRIVE_MAJOR): Change major number to one used by linux for
"user-mode virtual block device".
2003-09-28 15:46:00 +00:00
Corinna Vinschen 5c770c8431 * devices.h: Move a few device major numbers. Fix typo of FH_UDP.
* device.shilka: Remove /dev/hd device entries, rename all device_hd*
	to device_sd*.
	(device::parse): Disallow units outside lower and upper bounds.
	* dtable.cc (build_fh_pc): Fix typo of FH_UDP.
	* path.cc (win32_device_name): Fix win32 name creation to match new
	device handling.
2003-09-28 09:44:13 +00:00
Christopher Faylor 83abcab4c0 * device.shilka (device::parse): Allow units on other than tty. 2003-09-27 15:19:29 +00:00
Corinna Vinschen 658b4ff8fd * wincap.cc (wincapc::init): Allow requesting server info for NT4 SP6. 2003-09-27 08:14:56 +00:00
Christopher Faylor 341d295422 * path.cc (symlink_info::check): Use new introducer for mknod'ed files.
(parse_device): Ditto.
* syscalls.cc (mknod_worker): Ditto.
2003-09-27 05:44:58 +00:00
Christopher Faylor 4cb3e57917 * devices.shilka: Add /dev/sda disk devices.
* devices.cc: Regenerate.
2003-09-27 05:38:01 +00:00
Christopher Faylor 3c1e8187bd * cygwin-shilka: Remove '#line directives' or suffer debugging oddities. Use
-length option so that device prefixes are used.
* devices.cc: Regenerate.
* syscalls.cc (ttyname): Add debugging output.
2003-09-27 05:35:02 +00:00
Christopher Faylor dfb2ac8088 remove accidental checkin 2003-09-27 03:44:57 +00:00
Christopher Faylor aff9630767 * Makefile.in: Add libusr32.a to DLL_IMPORTS.
* wincap.h (wincaps::is_server): New flag.
(wincapc::version): Change type to OSVERSIONINFOEX.
(wincapc::is_server): New function.
* wincap.cc (wincap_unknown::is_server): New initializer.
(wincap_95): Ditto.
(wincap_95osr2): Ditto.
(wincap_98): Ditto.
(wincap_me): Ditto.
(wincap_nt3): Ditto.
(wincap_nt4): Ditto.
(wincap_nt4sp4): Ditto.
(wincap_2000): Ditto.
(wincap_xp): Ditto.
(wincapc::init): Adapt to OSVERSIONINFOEX.  Add detection of NT server systems.
* sched.cc: Include windows.h and registry.h.
(sched_rr_get_interval): Re-implement for NT systems.
2003-09-27 03:44:31 +00:00
Christopher Faylor a3cbb4a7e0 * fhandler_tty.cc (fhandler_tty_slave::ioctl): Properly set ioctl_request event
when window size changes.  Store failing errno in ioctl_retval (needed?).
2003-09-27 03:14:07 +00:00
Christopher Faylor 63726a5eb4 * fhandler_console.c (fhandler_console::read): Record the state of the SHIFT,
CTRL and ALT keys at the time of the last keyboard input event.
(fhandler_console::ioctl): Handle requests to retrieve the keyboard modifiers
via the TIOCLINUX command.
* fhandler_tty.c (fhandler_tty_slave::read): Ditto.
* include/sys/termios.h (TIOCLINUX): New macro definition.
2003-09-27 02:36:50 +00:00
Pierre Humblet ecc28ff8db 2003-09-26 Pierre Humblet <pierre.humblet@ieee.org>
* pinfo.cc (pinfo::init): Do not give FILE_MAP_WRITE access to Everybody.
	* exceptions.cc (sig_handle_tty_stop): Do not create pinfo parent with
	PID_MAP_WRITE.
	* fhandler_process.cc (fhandler_process::fill_filebuf): Ditto for pinfo p.
	* signal.cc (kill_worker): Ditto for pinfo dest.
2003-09-27 02:30:46 +00:00
Pierre Humblet 1eb451937a 2003-09-26 Pierre Humblet <pierre.humblet@ieee.org>
* pinfo.h (pinfo::set_acl): Declare.
	* pinfo.cc (pinfo_fixup_after_fork): Duplicate with no rights.
	(pinfo::set_acl): New.
	* spawn.cc (spawn_guts): Call myself.set_acl.
2003-09-27 01:58:23 +00:00
Pierre Humblet 6806a8b51f 2003-09-26 Pierre Humblet <pierre.humblet@ieee.org>
* uinfo.cc (cygheap_user::init): Make sure the current user appears
	in the default DACL. Rearrange to decrease the indentation levels.
	Initialize the effec_cygsid directly.
	(internal_getlogin): Do not reinitialize myself->gid. Open the process
	token with the required access.
	* cygheap.h (class cygheap_user): Delete members pid and saved_psid.
	Create members effec_cygsid and saved_cygsid.
	(cygheap_user::set_sid): Define inline.
	(cygheap_user::set_saved_sid): Ditto.
	(cygheap_user::sid): Modify.
	(cygheap_user::saved_sid): Modify.
	* cygheap.cc (cygheap_user::set_sid): Delete.
	(cygheap_user::set_saved_sid): Ditto.
	* sec_helper.cc (sec_acl): Set the correct acl size.
	* autoload.cc (FindFirstFreeAce): Add.
	* security.h: Define ACL_DEFAULT_SIZE.
2003-09-27 01:56:36 +00:00
Dimitri Papadopoulos 349a6402fe * include/winable.h (BlockInput): Add function.
* include/winable.h (WS_ACTIVECAPTION): Add constant.
	For use with WINDOWINFO structure.

	* include/winuser.h [_WIN32_WINNT >= 0x0500] (LockWorkStation):
	Add function.

	* include/winuser.h [_WIN32_WINNT >= 0x0501] (IsWinEventHookInstalled):
	Add function.

	* include/winuser.h [WINVER >= 0x0500] (UnhookWinEvent):
	Add function...

	* include/winable.h [WINVER < 0x0500] (UnhookWinEvent):
	...and duplicate.

	* include/winuser.h [_WIN32_WINNT >= 0x0403] (SendInput):
	Guard function...

	* include/winable.h [_WIN32_WINNT < 0x0403] (SendInput):
	...and duplicate.

	* include/winuser.h [WINVER >= 0x0500] (NotifyWinEvent):
	Guard function...

	* include/winable.h [WINVER < 0x0500] (NotifyWinEvent):
	...and duplicate.

	* include/winuser.h [WINVER >= 0x0500] (MOUSEINPUT, KEYBDINPUT,
	HARDWAREINPUT, INPUT): Guard structures...

	* include/winable.h [WINVER < 0x0500] (MOUSEINPUT, KEYBDINPUT,
	HARDWAREINPUT, INPUT): ...and duplicate.

	* include/winuser.h [_WIN32_WINNT >= 0x0403] (INPUT_MOUSE,
	INPUT_KEYBOARD, INPUT_HARDWARE): Guard constants...

	* include/winable.h [_WIN32_WINNT < 0x0403] (INPUT_MOUSE,
	INPUT_KEYBOARD, INPUT_HARDWARE): ...and duplicate.

	* include/winuser.h: Move around some lines. Reformat according
	to recommended or dominant style. Remove FAR keyword.

	* include/winable.h: Move around some lines.

	* lib/user32.def (BlockInput, IsWinEventHookInstalled,
	LockWorkStation, UnhookWinEvent): Add functions.
2003-09-26 14:46:33 +00:00
Dimitri Papadopoulos b6c1b88ad4 * include/winuser.h [_WIN32_WINNT >= 0x0501] (PrintWindow,
PW_CLIENTONLY): Add function and constant.

	* lib/user32.def (PrintWindow): Add function.
2003-09-26 10:41:23 +00:00
Dimitri Papadopoulos 46ffaf5071 * include/winuser.h (RealGetWindowClassA[AW]): Add function.
* lib/user32.def (RealGetWindowClassA[AW]): Add function.
2003-09-26 10:31:43 +00:00
Dimitri Papadopoulos 2bbffa5b85 * include/winuser.h [WINVER >= 0x0500] (RegisterDeviceNotification[AW],
DEVICE_NOTIFY_WINDOW_HANDLE, DEVICE_NOTIFY_SERVICE_HANDLE,
	DEVICE_NOTIFY_ALL_INTERFACE_CLASSES): Add function and constants.

	* lib/user32.def (RegisterDeviceNotification[AW]): Add function.
2003-09-26 10:20:46 +00:00
Dimitri Papadopoulos d7a6ce1ab5 * include/winuser.h [WINVER >= 0x0500] (SetWinEventHook, WINEVENTPROC,
WINEVENT_OUTOFCONTEXT, WINEVENT_SKIPOWNTHREAD, WINEVENT_SKIPOWNPROCESS,
	WINEVENT_INCONTEXT): Add function, typedef, and constants.

	* include/winable.h [WINVER < 0x0500] (SetWinEventHook, WINEVENTPROC,
	WINEVENT_OUTOFCONTEXT, WINEVENT_SKIPOWNTHREAD, WINEVENT_SKIPOWNPROCESS,
	WINEVENT_INCONTEXT): Add function, typedef, and constants.

	* include/winuser.h [_WIN32_WINNT >= 0x0500] (UserHandleGrantAccess):
	Add function.

	* lib/user32.def (SetWinEventHook, UserHandleGrantAccess):
	Add functions.
2003-09-26 09:49:52 +00:00
Corinna Vinschen 186a0e42de * mmap.cc (munmap): Use correct address and length parameters when
calling fhandler's munmap.
2003-09-26 08:50:12 +00:00
Corinna Vinschen 0a0a45e22a * spawn.cc (spawn_guts): Set errno to E2BIG if command line is
longer than CreateProcess allows (32K).
2003-09-26 08:45:24 +00:00
Dimitri Papadopoulos 8ff4b3513d * include/winnt.h (ACE_INHERITED_OBJECT_TYPE_PRESENT,
ACE_OBJECT_TYPE_PRESENT): Add constants. For use with
	OBJECTS_AND_NAME structure.
2003-09-26 08:19:30 +00:00
Dimitri Papadopoulos 72b0db800a * include/aclapi.h [_WIN32_WINNT >= 0x0501] (GetInheritanceSource[AW]):
Add functions. Don't know what PFN_OBJECT_MGR_FUNCTS is so use
	void* instead.

	* include/accctrl.h [_WIN32_WINNT >= 0x0501] (INHERITED_FROM[AW],
	PINHERITED_FROM[AW]): Add structures.

	* lib/user32.def (GetInheritanceSource[AW]): Add functions.
2003-09-26 08:07:39 +00:00
Corinna Vinschen 32c9d3a91c Avoid compile time error when including winuser.h:
* include/winuser.h (FLASHWINFO, PFLASHWINFO): Define for 98/Me, too.
2003-09-26 07:51:26 +00:00
Christopher Faylor 912f81352f * dtable.cc (build_fh_name): Return pointer to a 'nodevice' rather than a NULL
pointer or suffer SEGVs with invalid paths.
2003-09-26 03:26:44 +00:00
Christopher Faylor 6c68fbbc61 * fork.cc (fork_parent): Detect failed pinfo constructor.
* spawn.cc (spawn_guts): Don't overwrite ENOMEM errno on failed pinfo
constructor.
2003-09-26 03:20:30 +00:00
Christopher Faylor 177989407a * spawn.cc (spawnve): Remove vfork short circuit and let caller deal with error
return.
2003-09-26 03:09:42 +00:00
Christopher Faylor 570be9788f * spawn.cc (spawn_guts): Catch potential error from pinfo.remember. Change
debug messages to make sense.  Pass correct value to pinfo constructor.  Ensure
cleanup after errors.  Always reimpersonate after errors.
2003-09-26 02:23:34 +00:00
Danny Smith 711d0c752a * lib/version.def (LIBRARY): Quote name. 2003-09-25 20:24:05 +00:00
Dimitri Papadopoulos e9c00b0eeb * include/winuser.h (GetClipboardSequenceNumber): Add functions
and constants.
* include/winuser.h (GetGuiResources, GR_GDIOBJECTS,
GR_USEROBJECTS): Add functions and constants.
* include/winuser.h (GetMouseMovePointsEx, GMMP_USE_DISPLAY_POINTS,
GMMP_USE_HIGH_RESOLUTION_POINTS): Add functions and constants.
* include/winuser.h (InSendMessageEx, ISMEX_NOSEND, ISMEX_CALLBACK,
ISMEX_NOTIFY, ISMEX_REPLIED, ISMEX_SEND): Add functions and
constants.
* lib/user32.def (GetClipboardSequenceNumber, GetGuiResources,
GetMouseMovePointsEx, InSendMessageEx): Add functions.
2003-09-25 15:04:55 +00:00
Dimitri Papadopoulos d20c4a577d * include/winuser.h (BroadcastSystemMessage, BroadcastSystemMessageA,
BroadcastSystemMessageW, BroadcastSystemMessageEx,
BroadcastSystemMessageExA, BroadcastSystemMessageExW,
BSMINFO, BSF_ALLOWSFW, BSF_SENDNOTIFYMESSAGE, BSF_LUID,
BSF_RETURNHDESK): Add functions and constants.
* include/winuser.h (EnumDisplaySettingsEx, EnumDisplaySettingsExA,
EnumDisplaySettingsExW, EDS_RAWMODE): Add functions and constant.
* include/winuser.h (IsGUIThread, IsHungAppWindow, FlashWindowEx,
GetProcessDefaultLayout, SetProcessDefaultLayout,
RealChildWindowFromPoint, SetProcessDefaultLayout,
SwitchToThisWindow): Add functions.
* lib/user32.def (BroadcastSystemMessageA, BroadcastSystemMessageW,
BroadcastSystemMessageExA, BroadcastSystemMessageExW,
EnumDisplaySettingsExA, EnumDisplaySettingsExW, FlashWindowEx,
GetProcessDefaultLayout, IsGUIThread, IsHungAppWindow,
RealChildWindowFromPoint, SetProcessDefaultLayout,
SwitchToThisWindow): Add function.
2003-09-25 14:11:47 +00:00
Christopher Faylor b498c877a1 * spawn.cc (spawn_guts): Move system signal handling stuff after CreateProcess
error check.
2003-09-25 13:49:21 +00:00