diff options
| author | Paul Eggert | 2016-05-01 18:09:29 -0700 |
|---|---|---|
| committer | Paul Eggert | 2016-05-01 18:09:29 -0700 |
| commit | c3ed7cea0a43ab86c9d3b1627878055844bc8656 (patch) | |
| tree | 4a46db8032e1b359be5284822828d12814d96e27 /src | |
| parent | 07fafe1edbba4a5eecbe133313b2eb6ec15e5c55 (diff) | |
| parent | 16e5e8e4ea4ad46157fcdeafb16f245124fba375 (diff) | |
| download | emacs-c3ed7cea0a43ab86c9d3b1627878055844bc8656.tar.gz emacs-c3ed7cea0a43ab86c9d3b1627878055844bc8656.zip | |
Merge from origin/emacs-25
16e5e8e Fix last change to isearch-update (bug#23406)
b755d98 Autoload cursor-sensor-inhibit (bug#23406)
b52ebd4 org-map-entries: Fix org-agenda-prepare-buffers call
86aa409 Followup for last commit in the user manual
7004459 Improve doc string of 'set-goal-column'
ccdaf04 Fix the MSDOS build
ffe701c Remove \= from format string (bug#18190)
1c58fa1 Fix variable-pitch font on MS-Windows
c6077bf Restore follow-scroll-up/down to scrolling by the combined si...
b671e21 Revert unneeded change which harms syntactic parsing. This f...
48b24c9 Correct indentation of ids in a C++ enum after a protection k...
5c3534f * lisp/window.el (window--process-window-list): No-op if no p...
734fb3a Port dumping to NetBSD with PaX
0255a70 Don't mistake `for' inside a function for a part of array com...
# Conflicts:
# src/Makefile.in
Diffstat (limited to 'src')
| -rw-r--r-- | src/Makefile.in | 18 | ||||
| -rw-r--r-- | src/atimer.c | 4 | ||||
| -rw-r--r-- | src/conf_post.h | 3 | ||||
| -rw-r--r-- | src/deps.mk | 4 | ||||
| -rw-r--r-- | src/dosfns.h | 4 | ||||
| -rw-r--r-- | src/emacs.c | 1 | ||||
| -rw-r--r-- | src/filelock.c | 19 | ||||
| -rw-r--r-- | src/fns.c | 5 | ||||
| -rw-r--r-- | src/frame.c | 11 | ||||
| -rw-r--r-- | src/lread.c | 4 | ||||
| -rw-r--r-- | src/msdos.c | 36 | ||||
| -rw-r--r-- | src/msdos.h | 14 | ||||
| -rw-r--r-- | src/process.c | 39 | ||||
| -rw-r--r-- | src/w16select.c | 5 |
14 files changed, 114 insertions, 53 deletions
diff --git a/src/Makefile.in b/src/Makefile.in index fc9360a5bde..8639effde86 100644 --- a/src/Makefile.in +++ b/src/Makefile.in | |||
| @@ -114,8 +114,9 @@ TEMACS_LDFLAGS = $(LD_SWITCH_SYSTEM) $(LD_SWITCH_SYSTEM_TEMACS) | |||
| 114 | ## around this, newer ones setfattr. See Bug#11398 and Bug#16343. | 114 | ## around this, newer ones setfattr. See Bug#11398 and Bug#16343. |
| 115 | PAXCTL = @PAXCTL@ | 115 | PAXCTL = @PAXCTL@ |
| 116 | SETFATTR = @SETFATTR@ | 116 | SETFATTR = @SETFATTR@ |
| 117 | PAXCTL_if_present = $(or $(PAXCTL),: paxctl) | 117 | ## Commands to set PaX flags on dumped and not-dumped instances of Emacs. |
| 118 | SETFATTR_if_present = $(or $(SETFATTR),: setfattr) | 118 | PAXCTL_dumped = @PAXCTL_dumped@ |
| 119 | PAXCTL_notdumped = @PAXCTL_notdumped@ | ||
| 119 | 120 | ||
| 120 | ## Some systems define this to request special libraries. | 121 | ## Some systems define this to request special libraries. |
| 121 | LIBS_SYSTEM=@LIBS_SYSTEM@ | 122 | LIBS_SYSTEM=@LIBS_SYSTEM@ |
| @@ -542,7 +543,9 @@ ifeq ($(CANNOT_DUMP),yes) | |||
| 542 | ln -f temacs$(EXEEXT) $@ | 543 | ln -f temacs$(EXEEXT) $@ |
| 543 | else | 544 | else |
| 544 | LC_ALL=C $(RUN_TEMACS) -batch $(BUILD_DETAILS) -l loadup dump | 545 | LC_ALL=C $(RUN_TEMACS) -batch $(BUILD_DETAILS) -l loadup dump |
| 545 | $(PAXCTL_if_present) -zex $@ | 546 | ifneq ($(PAXCTL_dumped),) |
| 547 | $(PAXCTL_dumped) $@ | ||
| 548 | endif | ||
| 546 | ln -f $@ bootstrap-emacs$(EXEEXT) | 549 | ln -f $@ bootstrap-emacs$(EXEEXT) |
| 547 | endif | 550 | endif |
| 548 | 551 | ||
| @@ -606,8 +609,9 @@ temacs$(EXEEXT): $(LIBXMENU) $(ALLOBJS) \ | |||
| 606 | -o temacs $(ALLOBJS) $(LIBEGNU_ARCHIVE) $(W32_RES_LINK) $(LIBES) | 609 | -o temacs $(ALLOBJS) $(LIBEGNU_ARCHIVE) $(W32_RES_LINK) $(LIBES) |
| 607 | $(MKDIR_P) $(etc) | 610 | $(MKDIR_P) $(etc) |
| 608 | ifneq ($(CANNOT_DUMP),yes) | 611 | ifneq ($(CANNOT_DUMP),yes) |
| 609 | $(PAXCTL_if_present) -r $@ | 612 | ifneq ($(PAXCTL_notdumped),) |
| 610 | $(SETFATTR_if_present) -n user.pax.flags -v er $@ | 613 | $(PAXCTL_notdumped) $@ |
| 614 | endif | ||
| 611 | endif | 615 | endif |
| 612 | 616 | ||
| 613 | ## The following oldxmenu-related rules are only (possibly) used if | 617 | ## The following oldxmenu-related rules are only (possibly) used if |
| @@ -748,7 +752,9 @@ ifeq ($(CANNOT_DUMP),yes) | |||
| 748 | ln -f temacs$(EXEEXT) $@ | 752 | ln -f temacs$(EXEEXT) $@ |
| 749 | else | 753 | else |
| 750 | $(RUN_TEMACS) --batch $(BUILD_DETAILS) --load loadup bootstrap | 754 | $(RUN_TEMACS) --batch $(BUILD_DETAILS) --load loadup bootstrap |
| 751 | $(PAXCTL_if_present) -zex emacs$(EXEEXT) | 755 | ifneq ($(PAXCTL_dumped),) |
| 756 | $(PAXCTL_dumped) emacs$(EXEEXT) | ||
| 757 | endif | ||
| 752 | mv -f emacs$(EXEEXT) $@ | 758 | mv -f emacs$(EXEEXT) $@ |
| 753 | endif | 759 | endif |
| 754 | @: Compile some files earlier to speed up further compilation. | 760 | @: Compile some files earlier to speed up further compilation. |
diff --git a/src/atimer.c b/src/atimer.c index 70d9bf52bc2..64c9e8ab6cb 100644 --- a/src/atimer.c +++ b/src/atimer.c | |||
| @@ -30,6 +30,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 30 | # include <sys/timerfd.h> | 30 | # include <sys/timerfd.h> |
| 31 | #endif | 31 | #endif |
| 32 | 32 | ||
| 33 | #ifdef MSDOS | ||
| 34 | #include "msdos.h" | ||
| 35 | #endif | ||
| 36 | |||
| 33 | /* Free-list of atimer structures. */ | 37 | /* Free-list of atimer structures. */ |
| 34 | 38 | ||
| 35 | static struct atimer *free_atimers; | 39 | static struct atimer *free_atimers; |
diff --git a/src/conf_post.h b/src/conf_post.h index 047e3575e19..5d3394fafce 100644 --- a/src/conf_post.h +++ b/src/conf_post.h | |||
| @@ -134,6 +134,9 @@ You lose; /* Emacs for DOS must be compiled with DJGPP */ | |||
| 134 | # define HAVE_LSTAT 1 | 134 | # define HAVE_LSTAT 1 |
| 135 | #else | 135 | #else |
| 136 | # define lstat stat | 136 | # define lstat stat |
| 137 | /* DJGPP 2.03 and older don't have the next two. */ | ||
| 138 | # define EOVERFLOW ERANGE | ||
| 139 | # define SIZE_MAX 4294967295U | ||
| 137 | #endif | 140 | #endif |
| 138 | 141 | ||
| 139 | /* We must intercept 'opendir' calls to stash away the directory name, | 142 | /* We must intercept 'opendir' calls to stash away the directory name, |
diff --git a/src/deps.mk b/src/deps.mk index 0295e705a9c..72f68cabfc3 100644 --- a/src/deps.mk +++ b/src/deps.mk | |||
| @@ -35,7 +35,7 @@ | |||
| 35 | ### Code: | 35 | ### Code: |
| 36 | 36 | ||
| 37 | atimer.o: atimer.c atimer.h syssignal.h systime.h lisp.h blockinput.h \ | 37 | atimer.o: atimer.c atimer.h syssignal.h systime.h lisp.h blockinput.h \ |
| 38 | globals.h ../lib/unistd.h $(config_h) | 38 | globals.h ../lib/unistd.h msdos.h $(config_h) |
| 39 | bidi.o: bidi.c buffer.h character.h dispextern.h msdos.h lisp.h \ | 39 | bidi.o: bidi.c buffer.h character.h dispextern.h msdos.h lisp.h \ |
| 40 | globals.h $(config_h) | 40 | globals.h $(config_h) |
| 41 | buffer.o: buffer.c buffer.h region-cache.h commands.h window.h \ | 41 | buffer.o: buffer.c buffer.h region-cache.h commands.h window.h \ |
| @@ -92,7 +92,7 @@ editfns.o: editfns.c window.h buffer.h systime.h $(INTERVALS_H) character.h \ | |||
| 92 | emacs.o: emacs.c commands.h systty.h syssignal.h blockinput.h process.h \ | 92 | emacs.o: emacs.c commands.h systty.h syssignal.h blockinput.h process.h \ |
| 93 | termhooks.h buffer.h atimer.h systime.h $(INTERVALS_H) lisp.h $(config_h) \ | 93 | termhooks.h buffer.h atimer.h systime.h $(INTERVALS_H) lisp.h $(config_h) \ |
| 94 | globals.h ../lib/unistd.h window.h dispextern.h keyboard.h keymap.h \ | 94 | globals.h ../lib/unistd.h window.h dispextern.h keyboard.h keymap.h \ |
| 95 | frame.h coding.h gnutls.h msdos.h unexec.h | 95 | frame.h coding.h gnutls.h msdos.h dosfns.h unexec.h |
| 96 | fileio.o: fileio.c window.h buffer.h systime.h $(INTERVALS_H) character.h \ | 96 | fileio.o: fileio.c window.h buffer.h systime.h $(INTERVALS_H) character.h \ |
| 97 | coding.h msdos.h blockinput.h atimer.h lisp.h $(config_h) frame.h \ | 97 | coding.h msdos.h blockinput.h atimer.h lisp.h $(config_h) frame.h \ |
| 98 | commands.h globals.h ../lib/unistd.h | 98 | commands.h globals.h ../lib/unistd.h |
diff --git a/src/dosfns.h b/src/dosfns.h index 9fbf7eda192..849fb91a7af 100644 --- a/src/dosfns.h +++ b/src/dosfns.h | |||
| @@ -24,6 +24,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 24 | extern unsigned char dos_country_info[DOS_COUNTRY_INFO]; | 24 | extern unsigned char dos_country_info[DOS_COUNTRY_INFO]; |
| 25 | extern int dos_memory_info (unsigned long *, unsigned long *, | 25 | extern int dos_memory_info (unsigned long *, unsigned long *, |
| 26 | unsigned long *, unsigned long *); | 26 | unsigned long *, unsigned long *); |
| 27 | void dos_cleanup (void); | ||
| 28 | void syms_of_dosfns (void); | ||
| 29 | void init_dosfns (void); | ||
| 30 | |||
| 27 | #ifndef HAVE_X_WINDOWS | 31 | #ifndef HAVE_X_WINDOWS |
| 28 | extern int msdos_stdcolor_idx (const char *); | 32 | extern int msdos_stdcolor_idx (const char *); |
| 29 | extern Lisp_Object msdos_stdcolor_name (int); | 33 | extern Lisp_Object msdos_stdcolor_name (int); |
diff --git a/src/emacs.c b/src/emacs.c index a7cbb32e141..3e0cf596402 100644 --- a/src/emacs.c +++ b/src/emacs.c | |||
| @@ -54,6 +54,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 54 | 54 | ||
| 55 | #ifdef MSDOS | 55 | #ifdef MSDOS |
| 56 | #include <binary-io.h> | 56 | #include <binary-io.h> |
| 57 | #include "dosfns.h" | ||
| 57 | #endif | 58 | #endif |
| 58 | 59 | ||
| 59 | #ifdef HAVE_LIBSYSTEMD | 60 | #ifdef HAVE_LIBSYSTEMD |
diff --git a/src/filelock.c b/src/filelock.c index 6db6daa3bba..62017188b33 100644 --- a/src/filelock.c +++ b/src/filelock.c | |||
| @@ -53,6 +53,8 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 53 | #include "w32.h" /* for dostounix_filename */ | 53 | #include "w32.h" /* for dostounix_filename */ |
| 54 | #endif | 54 | #endif |
| 55 | 55 | ||
| 56 | #ifndef MSDOS | ||
| 57 | |||
| 56 | #ifdef HAVE_UTMP_H | 58 | #ifdef HAVE_UTMP_H |
| 57 | #include <utmp.h> | 59 | #include <utmp.h> |
| 58 | #endif | 60 | #endif |
| @@ -732,6 +734,19 @@ unlock_file (Lisp_Object fn) | |||
| 732 | SAFE_FREE (); | 734 | SAFE_FREE (); |
| 733 | } | 735 | } |
| 734 | 736 | ||
| 737 | #else /* MSDOS */ | ||
| 738 | void | ||
| 739 | lock_file (Lisp_Object fn) | ||
| 740 | { | ||
| 741 | } | ||
| 742 | |||
| 743 | void | ||
| 744 | unlock_file (Lisp_Object fn) | ||
| 745 | { | ||
| 746 | } | ||
| 747 | |||
| 748 | #endif /* MSDOS */ | ||
| 749 | |||
| 735 | void | 750 | void |
| 736 | unlock_all_files (void) | 751 | unlock_all_files (void) |
| 737 | { | 752 | { |
| @@ -795,6 +810,9 @@ The value is nil if the FILENAME is not locked, | |||
| 795 | t if it is locked by you, else a string saying which user has locked it. */) | 810 | t if it is locked by you, else a string saying which user has locked it. */) |
| 796 | (Lisp_Object filename) | 811 | (Lisp_Object filename) |
| 797 | { | 812 | { |
| 813 | #ifdef MSDOS | ||
| 814 | return Qnil; | ||
| 815 | #else | ||
| 798 | Lisp_Object ret; | 816 | Lisp_Object ret; |
| 799 | char *lfname; | 817 | char *lfname; |
| 800 | int owner; | 818 | int owner; |
| @@ -815,6 +833,7 @@ t if it is locked by you, else a string saying which user has locked it. */) | |||
| 815 | 833 | ||
| 816 | SAFE_FREE (); | 834 | SAFE_FREE (); |
| 817 | return ret; | 835 | return ret; |
| 836 | #endif | ||
| 818 | } | 837 | } |
| 819 | 838 | ||
| 820 | void | 839 | void |
| @@ -34,8 +34,13 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 34 | #include "intervals.h" | 34 | #include "intervals.h" |
| 35 | #include "window.h" | 35 | #include "window.h" |
| 36 | 36 | ||
| 37 | #if __GNUC__ >= 4 | ||
| 37 | static void sort_vector_copy (Lisp_Object, ptrdiff_t, | 38 | static void sort_vector_copy (Lisp_Object, ptrdiff_t, |
| 38 | Lisp_Object [restrict], Lisp_Object [restrict]); | 39 | Lisp_Object [restrict], Lisp_Object [restrict]); |
| 40 | #else | ||
| 41 | static void sort_vector_copy (Lisp_Object, ptrdiff_t, | ||
| 42 | Lisp_Object [], Lisp_Object []); | ||
| 43 | #endif | ||
| 39 | static bool internal_equal (Lisp_Object, Lisp_Object, int, bool, Lisp_Object); | 44 | static bool internal_equal (Lisp_Object, Lisp_Object, int, bool, Lisp_Object); |
| 40 | 45 | ||
| 41 | DEFUN ("identity", Fidentity, Sidentity, 1, 1, 0, | 46 | DEFUN ("identity", Fidentity, Sidentity, 1, 1, 0, |
diff --git a/src/frame.c b/src/frame.c index 9c8926c42c7..1c5c12c7e29 100644 --- a/src/frame.c +++ b/src/frame.c | |||
| @@ -509,10 +509,13 @@ adjust_frame_size (struct frame *f, int new_width, int new_height, int inhibit, | |||
| 509 | block_input (); | 509 | block_input (); |
| 510 | 510 | ||
| 511 | #ifdef MSDOS | 511 | #ifdef MSDOS |
| 512 | /* We only can set screen dimensions to certain values supported | 512 | /* We only can set screen dimensions to certain values supported by |
| 513 | by our video hardware. Try to find the smallest size greater | 513 | our video hardware. Try to find the smallest size greater or |
| 514 | or equal to the requested dimensions. */ | 514 | equal to the requested dimensions, while accounting for the fact |
| 515 | dos_set_window_size (&new_lines, &new_cols); | 515 | that the menu-bar lines are not counted in the frame height. */ |
| 516 | int dos_new_lines = new_lines + FRAME_TOP_MARGIN (f); | ||
| 517 | dos_set_window_size (&dos_new_lines, &new_cols); | ||
| 518 | new_lines = dos_new_lines - FRAME_TOP_MARGIN (f); | ||
| 516 | #endif | 519 | #endif |
| 517 | 520 | ||
| 518 | if (new_windows_width != old_windows_width) | 521 | if (new_windows_width != old_windows_width) |
diff --git a/src/lread.c b/src/lread.c index 44507281f2f..98a4d69894b 100644 --- a/src/lread.c +++ b/src/lread.c | |||
| @@ -47,6 +47,10 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 47 | 47 | ||
| 48 | #ifdef MSDOS | 48 | #ifdef MSDOS |
| 49 | #include "msdos.h" | 49 | #include "msdos.h" |
| 50 | #if __DJGPP__ == 2 && __DJGPP_MINOR__ < 5 | ||
| 51 | # define INFINITY __builtin_inf() | ||
| 52 | # define NAN __builtin_nan("") | ||
| 53 | #endif | ||
| 50 | #endif | 54 | #endif |
| 51 | 55 | ||
| 52 | #ifdef HAVE_NS | 56 | #ifdef HAVE_NS |
diff --git a/src/msdos.c b/src/msdos.c index 84e8c39ec0c..62411ea2f6d 100644 --- a/src/msdos.c +++ b/src/msdos.c | |||
| @@ -59,6 +59,12 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */ | |||
| 59 | #include <libc/dosio.h> /* for _USE_LFN */ | 59 | #include <libc/dosio.h> /* for _USE_LFN */ |
| 60 | #include <conio.h> /* for cputs */ | 60 | #include <conio.h> /* for cputs */ |
| 61 | 61 | ||
| 62 | #if (__DJGPP__ + (__DJGPP_MINOR__ > 3)) >= 3 | ||
| 63 | #define SYS_ENVIRON _environ | ||
| 64 | #else | ||
| 65 | #define SYS_ENVIRON environ | ||
| 66 | #endif | ||
| 67 | |||
| 62 | #include "msdos.h" | 68 | #include "msdos.h" |
| 63 | #include "systime.h" | 69 | #include "systime.h" |
| 64 | #include "frame.h" | 70 | #include "frame.h" |
| @@ -422,8 +428,6 @@ static unsigned long screen_old_address = 0; | |||
| 422 | /* Segment and offset of the virtual screen. If 0, DOS/V is NOT loaded. */ | 428 | /* Segment and offset of the virtual screen. If 0, DOS/V is NOT loaded. */ |
| 423 | static unsigned short screen_virtual_segment = 0; | 429 | static unsigned short screen_virtual_segment = 0; |
| 424 | static unsigned short screen_virtual_offset = 0; | 430 | static unsigned short screen_virtual_offset = 0; |
| 425 | extern Lisp_Object Qcursor_type; | ||
| 426 | extern Lisp_Object Qbar, Qhbar; | ||
| 427 | 431 | ||
| 428 | /* The screen colors of the current frame, which serve as the default | 432 | /* The screen colors of the current frame, which serve as the default |
| 429 | colors for newly-created frames. */ | 433 | colors for newly-created frames. */ |
| @@ -1384,11 +1388,6 @@ IT_delete_glyphs (struct frame *f, int n) | |||
| 1384 | 1388 | ||
| 1385 | /* This was copied from xfaces.c */ | 1389 | /* This was copied from xfaces.c */ |
| 1386 | 1390 | ||
| 1387 | extern Lisp_Object Qbackground_color; | ||
| 1388 | extern Lisp_Object Qforeground_color; | ||
| 1389 | Lisp_Object Qreverse; | ||
| 1390 | extern Lisp_Object Qtitle; | ||
| 1391 | |||
| 1392 | /* IT_set_terminal_modes is called when emacs is started, | 1391 | /* IT_set_terminal_modes is called when emacs is started, |
| 1393 | resumed, and whenever the screen is redrawn! */ | 1392 | resumed, and whenever the screen is redrawn! */ |
| 1394 | 1393 | ||
| @@ -3710,7 +3709,7 @@ dos_ttcooked (void) | |||
| 3710 | file TEMPOUT and stderr to TEMPERR. */ | 3709 | file TEMPOUT and stderr to TEMPERR. */ |
| 3711 | 3710 | ||
| 3712 | int | 3711 | int |
| 3713 | run_msdos_command (unsigned char **argv, const char *working_dir, | 3712 | run_msdos_command (char **argv, const char *working_dir, |
| 3714 | int tempin, int tempout, int temperr, char **envv) | 3713 | int tempin, int tempout, int temperr, char **envv) |
| 3715 | { | 3714 | { |
| 3716 | char *saveargv1, *saveargv2, *lowcase_argv0, *pa, *pl; | 3715 | char *saveargv1, *saveargv2, *lowcase_argv0, *pa, *pl; |
| @@ -3796,8 +3795,8 @@ run_msdos_command (unsigned char **argv, const char *working_dir, | |||
| 3796 | ; | 3795 | ; |
| 3797 | if (*cmnd) | 3796 | if (*cmnd) |
| 3798 | { | 3797 | { |
| 3799 | extern char **environ; | 3798 | extern char **SYS_ENVIRON; |
| 3800 | char **save_env = environ; | 3799 | char **save_env = SYS_ENVIRON; |
| 3801 | int save_system_flags = __system_flags; | 3800 | int save_system_flags = __system_flags; |
| 3802 | 3801 | ||
| 3803 | /* Request the most powerful version of `system'. We need | 3802 | /* Request the most powerful version of `system'. We need |
| @@ -3809,16 +3808,16 @@ run_msdos_command (unsigned char **argv, const char *working_dir, | |||
| 3809 | | __system_handle_null_commands | 3808 | | __system_handle_null_commands |
| 3810 | | __system_emulate_chdir); | 3809 | | __system_emulate_chdir); |
| 3811 | 3810 | ||
| 3812 | environ = envv; | 3811 | SYS_ENVIRON = envv; |
| 3813 | result = system (cmnd); | 3812 | result = system (cmnd); |
| 3814 | __system_flags = save_system_flags; | 3813 | __system_flags = save_system_flags; |
| 3815 | environ = save_env; | 3814 | SYS_ENVIRON = save_env; |
| 3816 | } | 3815 | } |
| 3817 | else | 3816 | else |
| 3818 | result = 0; /* emulate Unixy shell behavior with empty cmd line */ | 3817 | result = 0; /* emulate Unixy shell behavior with empty cmd line */ |
| 3819 | } | 3818 | } |
| 3820 | else | 3819 | else |
| 3821 | result = spawnve (P_WAIT, argv[0], (char **)argv, envv); | 3820 | result = spawnve (P_WAIT, argv[0], argv, envv); |
| 3822 | 3821 | ||
| 3823 | dup2 (inbak, 0); | 3822 | dup2 (inbak, 0); |
| 3824 | dup2 (outbak, 1); | 3823 | dup2 (outbak, 1); |
| @@ -4085,11 +4084,14 @@ sys_select (int nfds, fd_set *rfds, fd_set *wfds, fd_set *efds, | |||
| 4085 | gettime (&t); | 4084 | gettime (&t); |
| 4086 | clnow = make_timespec (t.tv_sec, t.tv_nsec); | 4085 | clnow = make_timespec (t.tv_sec, t.tv_nsec); |
| 4087 | cldiff = timespec_sub (clnow, cllast); | 4086 | cldiff = timespec_sub (clnow, cllast); |
| 4087 | /* Stop when timeout value is about to cross zero. */ | ||
| 4088 | if (timespec_cmp (*timeout, cldiff) <= 0) | ||
| 4089 | { | ||
| 4090 | timeout->tv_sec = 0; | ||
| 4091 | timeout->tv_nsec = 0; | ||
| 4092 | return 0; | ||
| 4093 | } | ||
| 4088 | *timeout = timespec_sub (*timeout, cldiff); | 4094 | *timeout = timespec_sub (*timeout, cldiff); |
| 4089 | |||
| 4090 | /* Stop when timeout value crosses zero. */ | ||
| 4091 | if (timespec_sign (*timeout) <= 0) | ||
| 4092 | return 0; | ||
| 4093 | cllast = clnow; | 4095 | cllast = clnow; |
| 4094 | dos_yield_time_slice (); | 4096 | dos_yield_time_slice (); |
| 4095 | } | 4097 | } |
diff --git a/src/msdos.h b/src/msdos.h index 863ca486e8d..0c3ba2bfa16 100644 --- a/src/msdos.h +++ b/src/msdos.h | |||
| @@ -41,8 +41,12 @@ void mouse_on (void); | |||
| 41 | void mouse_off (void); | 41 | void mouse_off (void); |
| 42 | void mouse_moveto (int, int); | 42 | void mouse_moveto (int, int); |
| 43 | 43 | ||
| 44 | void IT_set_frame_parameters (struct frame *, Lisp_Object); | ||
| 45 | |||
| 44 | #include <sys/types.h> | 46 | #include <sys/types.h> |
| 45 | #include <sys/stat.h> | 47 | #include <sys/stat.h> |
| 48 | #include <pc.h> | ||
| 49 | #include <signal.h> | ||
| 46 | 50 | ||
| 47 | #if __DJGPP__ == 2 && __DJGPP_MINOR__ < 4 | 51 | #if __DJGPP__ == 2 && __DJGPP_MINOR__ < 4 |
| 48 | int readlink (const char *, char *, size_t); | 52 | int readlink (const char *, char *, size_t); |
| @@ -50,6 +54,16 @@ int readlink (const char *, char *, size_t); | |||
| 50 | ssize_t readlinkat (int, const char *, char *, size_t); | 54 | ssize_t readlinkat (int, const char *, char *, size_t); |
| 51 | int fstatat (int, char const *, struct stat *, int); | 55 | int fstatat (int, char const *, struct stat *, int); |
| 52 | int unsetenv (const char *); | 56 | int unsetenv (const char *); |
| 57 | int faccessat (int, const char *, int, int); | ||
| 58 | void msdos_fatal_signal (int); | ||
| 59 | void syms_of_msdos (void); | ||
| 60 | int pthread_sigmask (int, const sigset_t *, sigset_t *); | ||
| 61 | int dos_keysns (void); | ||
| 62 | int dos_keyread (void); | ||
| 63 | int run_msdos_command (char **, const char *, int, int, int, char **); | ||
| 64 | |||
| 65 | void syms_of_win16select (void); | ||
| 66 | |||
| 53 | 67 | ||
| 54 | /* Constants. */ | 68 | /* Constants. */ |
| 55 | #define EINPROGRESS 112 | 69 | #define EINPROGRESS 112 |
diff --git a/src/process.c b/src/process.c index 0dfe1622971..9f2d379c330 100644 --- a/src/process.c +++ b/src/process.c | |||
| @@ -4278,19 +4278,6 @@ Data that is unavailable is returned as nil. */) | |||
| 4278 | #endif | 4278 | #endif |
| 4279 | } | 4279 | } |
| 4280 | 4280 | ||
| 4281 | /* If program file NAME starts with /: for quoting a magic | ||
| 4282 | name, remove that, preserving the multibyteness of NAME. */ | ||
| 4283 | |||
| 4284 | Lisp_Object | ||
| 4285 | remove_slash_colon (Lisp_Object name) | ||
| 4286 | { | ||
| 4287 | return | ||
| 4288 | ((SBYTES (name) > 2 && SREF (name, 0) == '/' && SREF (name, 1) == ':') | ||
| 4289 | ? make_specified_string (SSDATA (name) + 2, SCHARS (name) - 2, | ||
| 4290 | SBYTES (name) - 2, STRING_MULTIBYTE (name)) | ||
| 4291 | : name); | ||
| 4292 | } | ||
| 4293 | |||
| 4294 | /* Turn off input and output for process PROC. */ | 4281 | /* Turn off input and output for process PROC. */ |
| 4295 | 4282 | ||
| 4296 | static void | 4283 | static void |
| @@ -7483,6 +7470,19 @@ add_timer_wait_descriptor (int fd) | |||
| 7483 | 7470 | ||
| 7484 | #endif /* HAVE_TIMERFD */ | 7471 | #endif /* HAVE_TIMERFD */ |
| 7485 | 7472 | ||
| 7473 | /* If program file NAME starts with /: for quoting a magic | ||
| 7474 | name, remove that, preserving the multibyteness of NAME. */ | ||
| 7475 | |||
| 7476 | Lisp_Object | ||
| 7477 | remove_slash_colon (Lisp_Object name) | ||
| 7478 | { | ||
| 7479 | return | ||
| 7480 | ((SBYTES (name) > 2 && SREF (name, 0) == '/' && SREF (name, 1) == ':') | ||
| 7481 | ? make_specified_string (SSDATA (name) + 2, SCHARS (name) - 2, | ||
| 7482 | SBYTES (name) - 2, STRING_MULTIBYTE (name)) | ||
| 7483 | : name); | ||
| 7484 | } | ||
| 7485 | |||
| 7486 | /* Add DESC to the set of keyboard input descriptors. */ | 7486 | /* Add DESC to the set of keyboard input descriptors. */ |
| 7487 | 7487 | ||
| 7488 | void | 7488 | void |
| @@ -8010,13 +8010,6 @@ The variable takes effect when `start-process' is called. */); | |||
| 8010 | defsubr (&Sset_process_filter_multibyte); | 8010 | defsubr (&Sset_process_filter_multibyte); |
| 8011 | defsubr (&Sprocess_filter_multibyte_p); | 8011 | defsubr (&Sprocess_filter_multibyte_p); |
| 8012 | 8012 | ||
| 8013 | #endif /* subprocesses */ | ||
| 8014 | |||
| 8015 | defsubr (&Sget_buffer_process); | ||
| 8016 | defsubr (&Sprocess_inherit_coding_system_flag); | ||
| 8017 | defsubr (&Slist_system_processes); | ||
| 8018 | defsubr (&Sprocess_attributes); | ||
| 8019 | |||
| 8020 | { | 8013 | { |
| 8021 | Lisp_Object subfeatures = Qnil; | 8014 | Lisp_Object subfeatures = Qnil; |
| 8022 | const struct socket_options *sopt; | 8015 | const struct socket_options *sopt; |
| @@ -8049,4 +8042,10 @@ The variable takes effect when `start-process' is called. */); | |||
| 8049 | Fprovide (intern_c_string ("make-network-process"), subfeatures); | 8042 | Fprovide (intern_c_string ("make-network-process"), subfeatures); |
| 8050 | } | 8043 | } |
| 8051 | 8044 | ||
| 8045 | #endif /* subprocesses */ | ||
| 8046 | |||
| 8047 | defsubr (&Sget_buffer_process); | ||
| 8048 | defsubr (&Sprocess_inherit_coding_system_flag); | ||
| 8049 | defsubr (&Slist_system_processes); | ||
| 8050 | defsubr (&Sprocess_attributes); | ||
| 8052 | } | 8051 | } |
diff --git a/src/w16select.c b/src/w16select.c index 434a5987893..208cfccf11a 100644 --- a/src/w16select.c +++ b/src/w16select.c | |||
| @@ -65,8 +65,6 @@ unsigned get_clipboard_data (unsigned, void *, unsigned, int); | |||
| 65 | unsigned close_clipboard (void); | 65 | unsigned close_clipboard (void); |
| 66 | unsigned clipboard_compact (unsigned); | 66 | unsigned clipboard_compact (unsigned); |
| 67 | 67 | ||
| 68 | Lisp_Object QCLIPBOARD, QPRIMARY; | ||
| 69 | |||
| 70 | /* The segment address and the size of the buffer in low | 68 | /* The segment address and the size of the buffer in low |
| 71 | memory used to move data between us and WinOldAp module. */ | 69 | memory used to move data between us and WinOldAp module. */ |
| 72 | static struct { | 70 | static struct { |
| @@ -719,8 +717,7 @@ variable is set, it is used for the next communication only. | |||
| 719 | After the communication, this variable is set to nil. */); | 717 | After the communication, this variable is set to nil. */); |
| 720 | Vnext_selection_coding_system = Qnil; | 718 | Vnext_selection_coding_system = Qnil; |
| 721 | 719 | ||
| 722 | QPRIMARY = intern ("PRIMARY"); staticpro (&QPRIMARY); | 720 | DEFSYM (QCLIPBOARD, "CLIPBOARD"); |
| 723 | QCLIPBOARD = intern ("CLIPBOARD"); staticpro (&QCLIPBOARD); | ||
| 724 | } | 721 | } |
| 725 | 722 | ||
| 726 | #endif /* MSDOS */ | 723 | #endif /* MSDOS */ |