changeset 854:1d8fb2eee1bb

[xemacs-hg @ 2002-05-28 16:06:58 by didierv] Fix header inclusion order
author didierv
date Tue, 28 May 2002 16:07:03 +0000
parents 2b6fa2618f76
children 211050afdc9a
files src/ChangeLog src/emacs.c src/filelock.c src/nt.c src/process-nt.c src/process-unix.c src/process.c src/sysdep.c src/sysproc.h src/win32.c
diffstat 10 files changed, 142 insertions(+), 123 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Tue May 28 08:45:36 2002 +0000
+++ b/src/ChangeLog	Tue May 28 16:07:03 2002 +0000
@@ -1,7 +1,19 @@
+2002-05-28  Didier Verna  <didier@xemacs.org>
+
+	* emacs.c: comment the inclusion order of syssignal.h and sysproc.h.
+	* filelock.c: ditto.
+	* nt.c: ditto.
+	* sysproc.h: ditto.
+	* process-nt.c: ditto.
+	* process-unix.c: include syssignal.h before sysproc.h.
+	* process.c: ditto.
+	* sysdep.c: ditto.
+	* win32.c: ditto.
+
 2002-05-28  Ben Wing  <ben@xemacs.org>
 
 	================================================================
-   	       ALLOW SEPARATION OF STDOUT AND STDERR IN PROCESSES   
+   	       ALLOW SEPARATION OF STDOUT AND STDERR IN PROCESSES
 	================================================================
 
 	Standard output and standard error can be processed separately in
@@ -35,7 +47,7 @@
 	* process-unix.c (child_setup):
 	Delete callproc.c.  Move child_setup() to process-unix.c.
 	wait_for_termination() now only needed on a few really old systems.
-	
+
 	* console-msw.h:
 	* event-Xt.c (emacs_Xt_select_process):
 	* event-Xt.c (emacs_Xt_unselect_process):
@@ -131,7 +143,7 @@
 	as such changes are required throughout the entire process code.
 	Rewrote the code that reads process output to do two loops, one
 	for stdout and one for stderr.
-	
+
 	* gpmevent.c (get_process_infd):
 	* gpmevent.c (Fgpm_enable):
 	* tooltalk.c:
@@ -341,7 +353,7 @@
 	read-ahead queues, so we just get the C-g normal.
 
 	Signal.c documents this very carefully.
-	
+
 	* cmdloop.c (Fcommand_loop_1):
         Correct use of dont_check_for_quit to new scheme, remove old
         out-of-date comments.
@@ -362,7 +374,7 @@
 	* event-stream.c:
 	* event-stream.c (event_stream_next_event):
 	 Fix C-g handling to actually work.
-	
+
 	* device-x.c (get_device_from_display):
 	* device-x.c (x_error_handler):
 	* device-x.c (x_IO_error_handler):
@@ -392,7 +404,7 @@
 	free_cons() now takes a Lisp_Object not the result of XCONS().
 	car and cdr have been renamed so that they don't get used directly;
 	go through XCAR(), XCDR() instead.
-	
+
 	* alloc.c (Fcons):
 	* alloc.c (free_cons):
 	* alloc.c (free_list):
@@ -420,7 +432,7 @@
 	* lisp.h (cons_car):
         Correct free_cons calling convention: now takes Lisp_Object,
         not Lisp_Cons
-	
+
 	* chartab.c (word_boundary_p):
         Eliminate direct use of ->car, ->cdr, should be black box.
 
@@ -431,7 +443,7 @@
 	================================================================
                            USE INTERNAL-BIND-*
 	================================================================
-	
+
 	* eval.c (restore_lisp_object):
 	* eval.c (restore_int):
 	Cleanups of these funs.
@@ -471,7 +483,7 @@
 
 
 	================================================================
-                                SPECBIND SANITY   
+                                SPECBIND SANITY
 	================================================================
 
 	* backtrace.h:
@@ -494,7 +506,7 @@
 	Removed older prototype of same mechanism.
 
 	================================================================
-                                    MISC   
+                                    MISC
 	================================================================
 
 	* lisp.h:
@@ -540,13 +552,13 @@
 
 	* lisp.h (assert_with_message):
 	Add assert_with_message.
-	
+
 	* lisp.h (GCPRO1_ARRAY):
 	* lisp.h (NGCPRO1_ARRAY):
 	* lisp.h (NNGCPRO1_ARRAY):
 	Add macros for gcproing entire arrays. (You could do this before
 	but it required manual twiddling the gcpro structure.)
-	
+
 	* lisp.h:
         Add prototypes for new functions defined elsewhere.
 
@@ -706,12 +718,12 @@
 	Do save-restriction/widen around the function -- otherwise, incorrect
 	results will ensue when a buffer has been narrowed before a call to
 	e.g. `buffer-syntactic-context' -- something that happens quite often.
-	
+
 	* fileio.c:
 	* fileio.c (Fmake_temp_name):
 	* fileio.c (syms_of_fileio):
 	Look for a handler for make-temp-name.
-	
+
 	* window.c:
 	* window.c (allocate_window):
 	* window.c (Fset_window_point):
@@ -768,7 +780,7 @@
 
 	* callproc.c (Fold_call_process_internal):
 	Use Fget_buffer_create() with a string buffer, as documented.
-	
+
 	* extents.c (signal_extent_changed): indentation.
 
 	* lstream.c (lisp_buffer_reader): fix a bug in selective-display
@@ -798,22 +810,22 @@
 	* doprnt.c (emacs_doprnt_1):
 	Use make_int() not make_char() when error about bad charval,
 	or abort will occur.
-	
+
 	* extents.c (signal_extent_changed):
 	Loop over children, not ourself -- avoid infinite loop.
-	
+
 	* lisp-disunion.h:
 	* lisp-union.h:
 	Rename make_char() to make_char_1 for error-checking purposes.
-	
+
 	* lread.c (read_escape):
 	Syntax error if escape is outside of ISO-8859-1 range.
 	Remove hopelessly broken (and unworkable) FSF_KEYS code.
-	
+
 	* mule-coding.c (Fdecode_shift_jis_char):
 	* search.c (skip_chars):
 	Spacing changes.
-	
+
 	* text.h:
 	New make_char() -- verify that the char value is legal.
 
@@ -830,10 +842,10 @@
 	* console-msw.h:
 	* event-msw.c (mswindows_wnd_proc):
 	Condition references to menu accelerator functions on HAVE_MENUBARS.
-	
+
 	* frame-msw.c (mswindows_init_frame_3):
 	Remove obsolete runemacs hack which called ShowWindow() twice.
-	
+
 	* intl-auto-encap-win32.c:
 	* intl-auto-encap-win32.h:
 	* intl-encap-win32.c:
@@ -846,13 +858,13 @@
 	Disable .data section renaming hack when using portable dumping.
 	Force _WIN32_WINNT = 0x0400 since intl-auto-encap-win32.[ch]
 	requires this.
-	
+
 2002-05-05  Ben Wing  <ben@xemacs.org>
 
 	* Makefile.in.in (batch_test_emacs):
 
 	Fix so that packages are around when testing.
-	
+
 	* abbrev.c (struct abbrev_match_mapper_closure):
 	* abbrev.c (abbrev_match_mapper):
 	* abbrev.c (abbrev_match):
@@ -1585,7 +1597,7 @@
 	Another big Ben patch.
 
 	-- FUNCTIONALITY CHANGES:
-	
+
 	add partial support for 8-bit-fixed, 16-bit-fixed, and
 	32-bit-fixed formats.  not quite done yet. (in particular, needs
 	functions to actually convert the buffer.) NOTE: lots of changes
@@ -1599,7 +1611,7 @@
 	the relevant lisp info to the regex routines as local vars.
 
 	add general mechanism in extents code for signalling extent changes.
-	
+
 	fix numerous problems with the case-table implementation; yoshiki
 	never properly transferred many algorithms from old-style to
 	new-style case tables.
@@ -1620,9 +1632,9 @@
 	add more error-checking to buffer/string macros.
 
 	add some additional buffer_or_string_() funs.
-	
+
 	-- INTERFACE CHANGES AFFECTING MORE CODE:
-	
+
 	switch the arguments of write_c_string and friends to be
 	consistent with write_fmt_string, which must have printcharfun
 	first.
@@ -1634,7 +1646,7 @@
 	no-longer-needed CVOID_TO_LISP.
 
 	-- char/string macro changes:
-	
+
 	rename MAKE_CHAR() to make_emchar() for slightly less confusion
 	with make_char(). (The former generates an Emchar, the latter a
 	Lisp object.  Conceivably we should rename make_char() -> wrap_char()
@@ -1661,7 +1673,7 @@
 
 	here is a summary of most of the macros/inline funs changed by all
 	of the above changes:
-	
+
 	BYTE_*_P -> byte_*_p
 	XSTRING_BYTE -> string_byte
 	set_string_data/length -> set_lispstringp_data/length
@@ -1680,20 +1692,20 @@
 	REP_BYTES_BY_FIRST_BYTE -> rep_bytes_by_first_byte
 	char_to_unicode -> emchar_to_unicode
 	valid_char_p -> valid_emchar_p
-	
+
 	Change intbyte_strcmp -> qxestrcmp_c (duplicated functionality).
-		
+
 	-- INTERFACE CHANGES AFFECTING LESS CODE:
 
 	use DECLARE_INLINE_HEADER in various places.
 
 	remove '#ifdef emacs' from XEmacs-only files.
-	
+
 	eliminate CHAR_TABLE_VALUE(), which duplicated the functionality
 	of get_char_table().
-	
+
 	add BUFFER_TEXT_LOOP to simplify iterations over buffer text.
-	
+
 	define typedefs for signed and unsigned types of fixed sizes
 	(INT_32_BIT, UINT_32_BIT, etc.).
 
@@ -1780,7 +1792,7 @@
 
 2002-04-02  Andy Piper  <andy@xemacs.org>
 
-	* dired-msw.c (mswindows_get_files): 
+	* dired-msw.c (mswindows_get_files):
 	* nt.c (mswindows_stat): SetErrorMode() so that file errors are
 	completely handled by XEmacs. Suggested by Thomas Vogler
 	<mail@thomas-vogler.de>.
@@ -1876,7 +1888,7 @@
 	workspace, in which I make use of the new types Charxpos,
 	Bytexpos, Memxpos, representing a "position" either in a buffer or
 	a string. (This is especially important in the extent code.)
-	
+
 	* abbrev.c:
 	* abbrev.c (abbrev_oblookup):
 	* alloc.c (STRING_CHARS_BLOCK_SIZE):
@@ -1935,7 +1947,7 @@
 	SPECBIND_FAST_UNSAFE to be faster.
 	-- move the check for need to garbage collect into the allocation
 	code, so only a single flag needs to be checked in funcall.
-	
+
 
 	* buffer.c (Fstring_char_byte_converion_info):
 	* buffer.c (syms_of_buffer):
@@ -2038,7 +2050,7 @@
 	eliminate unused crufty vintage-19 "FSF defun hack" code.
 
 	* lrecord.h: improve pdump description docs.
-	
+
 	* buffer.c:
 	* ntheap.c:
 	* ntheap.c (round_to_next):
@@ -2079,7 +2091,7 @@
 	error has occurred, because it will wedge if we are in an inner
 	modal loop (typically when a menu is popped up) and make us unable
 	to get a useful stack trace in the debugger.
-	
+
 	* text.c (update_entirely_ascii_p_flag):
 	* text.c (charbpos_to_bytebpos_func):
 	* text.c (bytebpos_to_charbpos_func):
@@ -2099,12 +2111,12 @@
 
 2002-04-07  William M. Perry  <wmperry@gnu.org>
 
-	* event-gtk.c: 
-	* device-gtk.c: 
-	* glyphs-gtk.c: 
-	* frame-gtk.c: 
-	* gtk-xemacs.c: 
-	* menubar-gtk.c: 
+	* event-gtk.c:
+	* device-gtk.c:
+	* glyphs-gtk.c:
+	* frame-gtk.c:
+	* gtk-xemacs.c:
+	* menubar-gtk.c:
 	* redisplay-gtk.c: Need to include device.h and window.h in a few
 	places.  Not sure which .h has changed that was transparently
 	pulling them in before, but...
@@ -2155,7 +2167,7 @@
 	19.12.) Anyway, this introduced buffering issues, in which instead
 	of one char being read, it tried to read 1024 chars.  I tried
 	setting the stdin descriptor non-blocking, but it doesn't appear
-	to work on Cygwin. (#### Andy, do you know anything about this?) 
+	to work on Cygwin. (#### Andy, do you know anything about this?)
 	So I fixed it elsewhere.  If you get weirdness on the TTY, look in
 	console-tty.c and see how it gets the coding system; maybe there's
 	a way to change it (and if not, there should be!).
@@ -2248,7 +2260,7 @@
 
 	Add volatile_make_int() to fix warning in unix_send_process().
 
-	
+
 2002-03-31  Ben Wing  <ben@xemacs.org>
 
 	* s/windowsnt.h:
@@ -2499,14 +2511,14 @@
 
 	Clean up remaining places where nonintercepted Windows calls are
 	being used.
-	
+
 2002-03-29  Jonathan Harris  <jonathan@xemacs.org>
 
 	* device-msw.c (plist_get_margin): Add arg specifying mm or inches
 	* device-msw.c (plist_set_margin): Fix multiplicand used for mm
 	* device-msw.c (mswindows_handle_page_setup_dialog_box):
 	Detect and handle case where machine is set up for metric units
-	
+
 	* intl-auto-encap-win32.c:
 	* intl-auto-encap-win32.h:
 	* intl-encap-win32.c:
@@ -2514,9 +2526,9 @@
 
 2002-03-29  William M. Perry  <wmperry@gnu.org>
 
-	* ui-gtk.c (Fgtk_import_function_internal): 
-	(emacs_gtk_object_finalizer): 
-	(build_gtk_object): 
+	* ui-gtk.c (Fgtk_import_function_internal):
+	(emacs_gtk_object_finalizer):
+	(build_gtk_object):
 	(build_gtk_boxed): Use wrap_emacs_*() instead of wrap_*()
 	for gtk_boxed, gtk_object, ffi
 
@@ -2525,7 +2537,7 @@
 	* Makefile.in.in (gui_objs):
 	* Makefile.in.in (objs):
 	Always include gui.c, to fix compile error when TTY-only.
-	
+
 	* EmacsFrame.c (EmacsFrameSetValues):
 	* abbrev.c:
 	* abbrev.c (abbrev_match_mapper):
@@ -3267,11 +3279,11 @@
 	New fun Dynarr_verify(); use for further error checking on Dynarrs.
 
 	Rearrange code at top of lisp.h in conjunction with dynarr changes.
-	
+
 	Fix eifree().  Use Eistrings in various places
 	(format_event_object(), where_is_to_char(), and callers thereof)
 	to avoid fixed-size strings buffers.  New fun write_eistring().
-	
+
 	Reindent and fix GPM code to follow standards.
 
 	Set default MS Windows font to Lucida Console (same size as
@@ -3303,13 +3315,13 @@
 	like that.) The problem was that the glyph-contrib-p setting on
 	glyphs was ignored even if it was set properly, which it wasn't
 	until now.
-	
+
 2002-03-14  Mike Alexander  <mta@arbortext.com>
 
 	* event-msw.c (mswindows_unwait_process): New, remove process from
 	wait list
 	* process-nt.c (nt_finalize_process_data): Call
-	mswindows_unwait_process 
+	mswindows_unwait_process
 	* console-msw.h: Declare mswindows_unwait_process
 
 2002-03-21  William M. Perry  <wmperry@gnu.org>
@@ -3331,7 +3343,7 @@
 	* chartab.c (Fcheck_category_at):
 	* chartab.c (Fchar_in_category_p):
 	Fix bugs in implementation and doc strings.
-	
+
 	* config.h.in (type_checking_assert_at_line):
 	Add foo_checking_assert_at_line() macros.  Not clear whether these
 	are actually useful, though; I'll take them out if not.
@@ -3342,7 +3354,7 @@
 	Some improvements to the timeline.  Rearrange a bit the init
 	calls.  Add call for reinit_vars_of_object_mswindows() and
 	declare in symsinit.h.
-	
+
 	* event-Xt.c:
 	* event-Xt.c (emacs_Xt_format_magic_event):
 	* event-Xt.c (describe_event_window):
@@ -3386,7 +3398,7 @@
 	stream, not always to stderr, so it can be used
 	elsewhere. (e.g. in print-event when a magic event is
 	encountered?)
-	
+
 	* lisp.h:
 	* lisp.h (XCHAR_1):
 	* lisp.h (XCHAR):
@@ -3408,14 +3420,14 @@
 	assert_at_line().  Happens only when error-checking is defined so
 	doesn't slow down non-error-checking builds.  Fix XCHAR, XINT,
 	XCHAR_OR_INT, XFOO, and wrap_foo() in this fashion.
-	
+
 	* lstream.c:
 	* lstream.c (resizing_buffer_stream_ptr):
 	* lstream.h:
 	Add resizing_buffer_to_lisp_string().
-	
+
 	* objects-gtk.c (gtk_find_charset_font): Fix typo.
-	
+
 	* objects-msw.c:
 	* objects-msw.c (create_hfont_from_font_spec):
 	* objects-msw.c (initialize_font_instance):
@@ -3432,7 +3444,7 @@
 	char-by-char), and see if any of the font's supported ranges
 	include the charset's range.  also do some caching in
 	Vfont_signature_data of previous inquiries.
-	
+
 	* charset.h:
 	* text.c (Fmake_char):
 	* mule-charset.c (get_charset_limits): New fun; extracted out of
@@ -3545,7 +3557,7 @@
 
 	* .cvsignore:
 	ignore .tmp files that are getting auto-created by VC.
-	
+
 	* Makefile.in.in (release):
 	* Makefile.in.in (fastdump):
 	* Makefile.in.in (dynodump_deps):
@@ -3600,7 +3612,7 @@
 
 2002-02-11  Mike Sperber  <mike@xemacs.org>
 
-	* device-x.c: 
+	* device-x.c:
 	(x_IO_error_handler):
 	(x_init_device): Temporarily keep device in static variable
 	`device_being_initialized' so we can recover gracefully from
@@ -3722,9 +3734,9 @@
 	expose it in our method structure.
 	(gtk_ring_bell): Don't ring the bell if volume <= 0
 
-	* toolbar-gtk.c (gtk_output_toolbar_button): 
-	(gtk_output_frame_toolbars): 
-	(gtk_redraw_exposed_toolbars): 
+	* toolbar-gtk.c (gtk_output_toolbar_button):
+	(gtk_output_frame_toolbars):
+	(gtk_redraw_exposed_toolbars):
 	(gtk_redraw_frame_toolbars): These are now just aliases for the
 	common_XXX() routines in toolbar-common.c
 
--- a/src/emacs.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/emacs.c	Tue May 28 16:07:03 2002 +0000
@@ -233,7 +233,7 @@
 version 18.59 released October 31, 1992.
 
 */
-   
+
 /* Note: It is necessary to specify <config.h> and not "config.h" in
    order for the --srcdir type of compilation to work properly.
    Otherwise the config.h from the srcdir, rather than the one from
@@ -251,7 +251,7 @@
 #include "frame.h"
 #include "sysdep.h"
 
-#include "syssignal.h" /* Always include before systty.h */
+#include "syssignal.h" /* Always include before systty.h and sysproc.h */
 #include "systty.h"
 #include "sysfile.h"
 #include "systime.h"
@@ -730,7 +730,7 @@
      startup.el, which is way late.  We need to be dumping the Unicode
      data, which means we need to fix pdump to correctly dump the "union"
      format used by the tables. */
-  
+
 #if (!defined (SYSTEM_MALLOC) && !defined (HAVE_LIBMCHECK)	\
      && !defined (DOUG_LEA_MALLOC))
   /* Make sure that any libraries we link against haven't installed a
@@ -826,7 +826,7 @@
      arguments below in standard_args[], with the help text in startup.el,
      and with the list of non-clobbered variables near where pdump_load()
      is called! */
-  
+
   /* Handle the -sd/--show-dump-id switch, which means show the hex dump_id
      and quit */
   if (argmatch (argv, argc, "-sd", "--show-dump-id", 0, NULL, &skip_args))
@@ -838,7 +838,7 @@
 #endif
       exit (0);
     }
-  
+
   /* Handle the -t switch, which specifies filename to use as terminal */
   {
     Extbyte *term;
@@ -890,7 +890,7 @@
        suicide. (This is cleaner than using TerminateProcess()).  This
        makes (e.g.) the "Stop Build" command from VC++ correctly terminate
        XEmacs. */
-    
+
     char *heventstr;
     if (argmatch (argv, argc, "-mswindows-termination-handle", 0, 0,
 		  &heventstr, &skip_args))
@@ -936,7 +936,7 @@
 		0, NULL, &skip_args))
 #endif
     inhibit_site_modules = 1;
-  
+
   if (argmatch (argv, argc, "-vanilla", "--vanilla",
 		0, NULL, &skip_args))
     {
@@ -1308,7 +1308,7 @@
       syms_of_menubar_gtk ();
 #endif
       syms_of_select_gtk ();
-      
+
 #ifdef HAVE_GUI_OBJECTS
       syms_of_gui_gtk ();
 #endif
@@ -3030,7 +3030,7 @@
   EMACS_SIGNAL (SIGBUS, old_sigbus);
   EMACS_SIGNAL (SIGSEGV, old_sigsegv);
   errno = old_errno;
-      
+
   return retval;
 }
 
@@ -3311,7 +3311,7 @@
 #ifdef HAVE_MS_WINDOWS
   pause_so_user_can_read_messages (1);
 #endif
-  
+
   shut_down_emacs (0, STRINGP (arg) ? arg : Qnil, 0);
 
 #if defined(GNU_MALLOC)
@@ -3348,7 +3348,7 @@
 #define USER_IS_DEVELOPING_XEMACS
 #endif
 
-					      
+
 /* Handle bus errors, illegal instruction, etc: actual implementation. */
 static void
 guts_of_fatal_error_signal (int sig)
--- a/src/filelock.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/filelock.c	Tue May 28 16:07:03 2002 +0000
@@ -29,7 +29,8 @@
 #include "sysfile.h"
 #include "sysdir.h"
 #include "syspwd.h"
-#include "syssignal.h" /* for kill */
+#include "syssignal.h" /* for kill. Always include before sysproc.h
+			  -- didier */
 #include "sysproc.h" /* for qxe_getpid() */
 
 Lisp_Object Qask_user_about_supersession_threat;
--- a/src/nt.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/nt.c	Tue May 28 16:07:03 2002 +0000
@@ -41,7 +41,7 @@
 #include "buffer.h"
 
 #include "systime.h"
-#include "syssignal.h"
+#include "syssignal.h" /* Always include before sysproc.h -- didier */
 #include "sysproc.h"
 #include "sysfile.h"
 #include "syspwd.h"
--- a/src/process-nt.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/process-nt.c	Tue May 28 16:07:03 2002 +0000
@@ -34,7 +34,7 @@
 #include "process.h"
 #include "procimpl.h"
 
-#include "syssignal.h"
+#include "syssignal.h" /* Always include before sysproc.h -- didier */
 #include "sysfile.h"
 #include "sysproc.h"
 
@@ -127,11 +127,11 @@
  * The memory in other process is allocated by creating a suspended
  * thread. Initial stack of that thread is used as the memory
  * block. The thread entry point is the routine ExitThread in
- * kernel32.dll, so the allocated memory is freed just by resuming the 
+ * kernel32.dll, so the allocated memory is freed just by resuming the
  * thread, which immediately terminates after that.
  */
 
-static int 
+static int
 alloc_process_memory (HANDLE h_process, Bytecount size,
 		      process_memory *pmc)
 {
@@ -335,9 +335,9 @@
   HMODULE h_kernel = qxeGetModuleHandle (XETEXT ("kernel32"));
   int close_process = 0;
   DWORD retval;
-  
+
   assert (h_kernel != NULL);
-  
+
   if (cp)
     {
       pid = cp->dwProcessId;
@@ -348,7 +348,7 @@
       close_process = 1;
       /* Try to open the process with required privileges */
       h_process = OpenProcess (PROCESS_CREATE_THREAD
-			       | PROCESS_QUERY_INFORMATION 
+			       | PROCESS_QUERY_INFORMATION
 			       | PROCESS_VM_OPERATION
 			       | PROCESS_VM_WRITE,
 			       FALSE, pid);
@@ -368,7 +368,7 @@
 	d.adr_ExitProcess =
 	  (void (WINAPI *) (UINT)) GetProcAddress (h_kernel, "ExitProcess");
 	assert (d.adr_ExitProcess);
-	retval = run_in_other_process (h_process, 
+	retval = run_in_other_process (h_process,
 				       (LPTHREAD_START_ROUTINE) sigkill_proc,
 				       &d, sizeof (d));
 	break;
@@ -381,7 +381,7 @@
 	  GetProcAddress (h_kernel, "GenerateConsoleCtrlEvent");
 	assert (d.adr_GenerateConsoleCtrlEvent);
 	d.event = CTRL_C_EVENT;
-	retval = run_in_other_process (h_process, 
+	retval = run_in_other_process (h_process,
 				       (LPTHREAD_START_ROUTINE) sigint_proc,
 				       &d, sizeof (d));
 	break;
@@ -403,7 +403,7 @@
 {
   HMODULE h_kernel = qxeGetModuleHandle (XETEXT ("kernel32"));
   sig_enable_data d;
-  
+
   assert (h_kernel != NULL);
   d.adr_SetConsoleCtrlHandler =
     (BOOL (WINAPI *) (LPVOID, BOOL))
@@ -412,7 +412,7 @@
   run_in_other_process (h_process, (LPTHREAD_START_ROUTINE)sig_enable_proc,
 			&d, sizeof (d));
 }
-  
+
 /* ---------------------------- the 95 way ------------------------------- */
 
 static BOOL CALLBACK
@@ -448,7 +448,7 @@
   HANDLE h_process;
   int close_process = 0;
   int rc = 1;
-  
+
   if (cp)
     {
       pid = cp->dwProcessId;
@@ -465,7 +465,7 @@
       if (!h_process)
 	return 0;
     }
-    
+
   if (signo == SIGINT)
     {
       if (NILP (Vmswindows_start_process_share_console) && cp && cp->hwnd)
@@ -634,7 +634,7 @@
       && signo != SIGHUP)
     invalid_constant ("Signal number not supported", make_int (signo));
 }
-  
+
 /*-----------------------------------------------------------------------*/
 /* Process methods							 */
 /*-----------------------------------------------------------------------*/
@@ -786,7 +786,7 @@
      process is a console one, or if it is windowed but windowed_process_io
      is non-zero */
   do_io = !windowed || windowed_process_io ;
-  
+
   if (do_io)
     {
       /* Create two unidirectional named pipes */
@@ -864,7 +864,7 @@
     REGISTER Lisp_Object tem;
     REGISTER Intbyte **new_env;
     REGISTER int new_length = 0, i;
-    
+
     for (tem = Vprocess_environment;
  	 (CONSP (tem)
  	  && STRINGP (XCAR (tem)));
@@ -876,15 +876,15 @@
        which we have superseded by gnuserv.c. (#### Does it work under
        MS Windows?)
 
-       sprintf (ppid_env_var_buffer, "EM_PARENT_PROCESS_ID=%d", 
+       sprintf (ppid_env_var_buffer, "EM_PARENT_PROCESS_ID=%d",
          GetCurrentProcessId ());
        arglen += strlen (ppid_env_var_buffer) + 1;
        numenv++;
     */
-    
+
     /* new_length + 1 to include terminating 0.  */
     env = new_env = alloca_array (Intbyte *, new_length + 1);
- 
+
     /* Copy the Vprocess_environment strings into new_env.  */
     for (tem = Vprocess_environment;
  	 (CONSP (tem)
@@ -916,7 +916,7 @@
       duplicate: ;
       }
     *new_env = 0;
-    
+
     /* Sort the environment variables */
     new_length = new_env - env;
     qsort (env, new_length, sizeof (Intbyte *), mswindows_compare_env);
@@ -953,7 +953,7 @@
 	  }
       }
 #endif
-  
+
   /* Create process */
   {
     STARTUPINFOW si;
@@ -1004,7 +1004,7 @@
 	CloseHandle (hprocout);
 	CloseHandle (hprocerr);
       }
-    
+
     /* Handle process creation failure */
     if (err)
       {
@@ -1046,12 +1046,12 @@
   }
 }
 
-/* 
+/*
  * This method is called to update status fields of the process
  * structure. If the process has not existed, this method is expected
  * to do nothing.
  *
- * The method is called only for real child processes.  
+ * The method is called only for real child processes.
  */
 
 static void
@@ -1345,7 +1345,7 @@
     unsigned long nonblock = 1;
     ioctlsocket (s, FIONBIO, &nonblock);
   }
-  
+
   retval = connect (s, (struct sockaddr *) &address, sizeof (address));
   if (retval != NO_ERROR && WSAGetLastError() != WSAEWOULDBLOCK)
     {
--- a/src/process-unix.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/process-unix.c	Tue May 28 16:07:03 2002 +0000
@@ -53,9 +53,10 @@
 #include <setjmp.h>
 #include "sysdir.h"
 #include "sysfile.h"
+#include "syssignal.h" /* Always include before systty.h and sysproc.h
+			  -- didier*/
 #include "sysproc.h"
 #include "systime.h"
-#include "syssignal.h" /* Always include before systty.h */
 #include "systty.h"
 #include "syswait.h"
 
@@ -1106,13 +1107,13 @@
   if (separate_err)
     {
       int sv[2];
-      
+
       if (pipe (sv) < 0)
 	goto io_failure;
       forkerr = sv[1];
       errchannel = sv[0];
     }
-      
+
 #if 0
   /* Replaced by close_process_descs */
   set_exclusive_use (inchannel);
@@ -2047,7 +2048,7 @@
 		   at this point so we can use `sleep'.
 
 		   (Again, this was not conditionalized on FreeBSD.
-		   Let's not mess up systems without the problem. --ben) 
+		   Let's not mess up systems without the problem. --ben)
 		*/
 		sleep (1);
 #endif
--- a/src/process.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/process.c	Tue May 28 16:07:03 2002 +0000
@@ -57,8 +57,9 @@
 #include "window.h"
 
 #include "sysfile.h"
+#include "syssignal.h" /* Always include before sysproc.h and systty.h
+			  -- didier */
 #include "sysproc.h"
-#include "syssignal.h"
 #include "systime.h"
 #include "systty.h"
 #include "syswait.h"
@@ -994,7 +995,7 @@
 
   record_unwind_protect (save_excursion_restore, save_excursion_save ());
   specbind (Qinhibit_read_only, Qt);
-      
+
   /* Insert new output into buffer
      at the current end-of-output marker,
      thus preserving logical ordering of input and output.  */
@@ -1284,7 +1285,7 @@
 DEFUN ("set-process-filter", Fset_process_filter, 2, 2, 0, /*
 Give PROCESS the filter function FILTER; nil means no filter.
 t means stop accepting output from the process. (If process was created
-with 
+with
 When a process has a filter, each time it does output
 the entire string of output is passed to the filter.
 The filter gets two arguments: the process and the string of output.
@@ -2323,7 +2324,7 @@
    out of C and into Lisp is a good idea, but in this case the Lisp
    function is used so early in the startup sequence that it would be ugly
    to rearrange the early dumped code to accommodate this.
-   
+
 (defun getenv (variable)
   "Get the value of environment variable VARIABLE.
 VARIABLE should be a string.  Value is nil if VARIABLE is undefined in
@@ -2421,7 +2422,7 @@
     clrhash (usid_to_process);
   else
     usid_to_process = make_hash_table (32);
-  
+
   {
     /* jwz: always initialize Vprocess_environment, so that egetenv()
        works in temacs. */
@@ -2451,7 +2452,7 @@
     /* BAD BAD BAD.  We do not wanting to be passing an XEmacs-created
        SHELL var down to some inferior Cygwin process, which might get
        screwed up.
-	 
+
        There are a few broken apps (eterm/term.el, eterm/tshell.el,
        os-utils/terminal.el, texinfo/tex-mode.el) where this will
        cause problems.  Those broken apps don't look at
@@ -2462,7 +2463,7 @@
        at shell-file-name, so that the user can change the value of
        shell-file-name and everything will work out hunky-dorey.
        */
-    
+
     if (!egetenv ("SHELL"))
       {
 	Intbyte *faux_var = alloca_array (Intbyte, 7 + qxestrlen (shell));
--- a/src/sysdep.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/sysdep.c	Tue May 28 16:07:03 2002 +0000
@@ -67,10 +67,10 @@
 
 #include "sysdir.h"
 #include "sysfile.h"
+#include "syssignal.h" /* Always include before sysproc.h and systty.h
+			  -- didier */
 #include "sysproc.h"
 #include "syspwd.h"
-#include "syssignal.h"
-#include "syssignal.h"
 #include "systime.h"
 #include "systty.h"
 #include "syswait.h"
@@ -581,7 +581,7 @@
   /* Note: These calls are spread out to insure that the return values
      of the calls (which may be newly-created strings) are properly
      GC-protected. */
-  
+
   GCPRO1 (dir);
 
   dir = current_buffer->directory;
@@ -2191,7 +2191,7 @@
 #else
   void *data_start = minimum_address_seen;
 #endif
-  
+
 #if !defined (WIN32_NATIVE) && !defined (CYGWIN)
   void *data_end = sbrk (0);
 #else
--- a/src/sysproc.h	Tue May 28 08:45:36 2002 +0000
+++ b/src/sysproc.h	Tue May 28 16:07:03 2002 +0000
@@ -194,6 +194,10 @@
    --ben
 */
 
+/* #### WARNING: if you include this file somewhere, you must include
+   syssignal.h before in order to get SIGTSTP for the following define.
+   -- didier */
+
 #if !defined (WIN32_NATIVE) && ((!defined (SIGTSTP) && !defined (USG_JOBCTRL)) || !defined (HAVE_MKDIR) || !defined (HAVE_RMDIR))
 
 #define NEED_SYNC_PROCESS_CODE
--- a/src/win32.c	Tue May 28 08:45:36 2002 +0000
+++ b/src/win32.c	Tue May 28 16:07:03 2002 +0000
@@ -25,8 +25,8 @@
 #include "console-msw.h"
 
 #include "sysfile.h"
+#include "syssignal.h" /* Always include before sysproc.h -- didier */
 #include "sysproc.h"
-#include "syssignal.h"
 #include "systime.h"
 
 /* Control conversion of upper case file names to lower case.