aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2011-05-22 17:09:23 -0700
committerPaul Eggert2011-05-22 17:09:23 -0700
commitaf3d522ffbf83826f80ab8f6d811e19e97c37384 (patch)
tree4f3d6047a2e0a30c8374f2da5e02858b0129edac /src
parent37910ab2514f67d12c5b20b63ec6333c02df43c1 (diff)
parent7400048f602459209e89da4680ed9cc351ace4ee (diff)
downloademacs-af3d522ffbf83826f80ab8f6d811e19e97c37384.tar.gz
emacs-af3d522ffbf83826f80ab8f6d811e19e97c37384.zip
Merge from trunk.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog38
-rw-r--r--src/Makefile.in15
-rw-r--r--src/dispnew.c30
-rw-r--r--src/gnutls.c3
-rw-r--r--src/xselect.c79
5 files changed, 95 insertions, 70 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index b74d831d707..74f0bd52a5d 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -22,8 +22,6 @@
22 22
23 * lisp.h (FIXNUM_OVERFLOW_P): Work even if arg is a NaN. 23 * lisp.h (FIXNUM_OVERFLOW_P): Work even if arg is a NaN.
24 24
252011-05-21 Paul Eggert <eggert@cs.ucla.edu>
26
27 * data.c: Avoid integer truncation in expressions involving floats. 25 * data.c: Avoid integer truncation in expressions involving floats.
28 * data.c: Include <intprops.h>. 26 * data.c: Include <intprops.h>.
29 (arith_driver): When there's an integer overflow in an expression 27 (arith_driver): When there's an integer overflow in an expression
@@ -33,8 +31,6 @@
33 most-negative-fixnum 0.5) should yield about -4.6e+18, not zero. 31 most-negative-fixnum 0.5) should yield about -4.6e+18, not zero.
34 Do not rely on undefined behavior after integer overflow. 32 Do not rely on undefined behavior after integer overflow.
35 33
362011-05-20 Paul Eggert <eggert@cs.ucla.edu>
37
38 merge count_size_as_multibyte, parse_str_to_multibyte 34 merge count_size_as_multibyte, parse_str_to_multibyte
39 * character.c, character.h (count_size_as_multibyte): 35 * character.c, character.h (count_size_as_multibyte):
40 Renamed from parse_str_to_multibyte; all uses changed. 36 Renamed from parse_str_to_multibyte; all uses changed.
@@ -44,6 +40,40 @@
44 a character than a buffer op, so better that it's in character.c. 40 a character than a buffer op, so better that it's in character.c.
45 * fns.c, print.c: Adjust to above changes. 41 * fns.c, print.c: Adjust to above changes.
46 42
432011-05-22 Paul Eggert <eggert@cs.ucla.edu>
44
45 * gnutls.c: Remove unused macros.
46 (fn_gnutls_transport_set_lowat, fn_gnutls_transport_set_pull_function):
47 (fn_gnutls_transport_set_push_function) [!WINDOWSNT]:
48 Remove macros that are defined and never used.
49 Caught by gcc -Wunused-macros (GCC 4.6.0, Fedora 14).
50
512011-05-22 Chong Yidong <cyd@stupidchicken.com>
52
53 * xselect.c (syms_of_xselect): Remove unused symbol SAVE_TARGETS.
54 (Fx_get_selection_internal): Minor cleanup.
55 (Fx_own_selection_internal): Rename arguments for consistency with
56 select.el.
57
582011-05-22 Paul Eggert <eggert@cs.ucla.edu>
59
60 * xselect.c (QSAVE_TARGETS): New static var, to fix build failure.
61
622011-05-22 Chong Yidong <cyd@stupidchicken.com>
63
64 * xselect.c (syms_of_xselect): Include character.h; use DEFSYM.
65
662011-05-21 YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
67
68 * dispnew.c (scrolling_window): Don't exclude the case that the
69 last enabled row in the desired matrix touches the bottom boundary.
70
712011-05-21 Glenn Morris <rgm@gnu.org>
72
73 * Makefile.in ($(etc)/DOC): Make second command line even shorter.
74 (SOME_MACHINE_OBJECTS): Replace FONT_OBJ by its maximal expansion,
75 and add some more files.
76
472011-05-20 Eli Zaretskii <eliz@gnu.org> 772011-05-20 Eli Zaretskii <eliz@gnu.org>
48 78
49 * callproc.c (Fcall_process) [MSDOS]: Fix arguments to 79 * callproc.c (Fcall_process) [MSDOS]: Fix arguments to
diff --git a/src/Makefile.in b/src/Makefile.in
index 557a6f54748..c4250b90633 100644
--- a/src/Makefile.in
+++ b/src/Makefile.in
@@ -149,11 +149,13 @@ M17N_FLT_LIBS = @M17N_FLT_LIBS@
149 149
150DBUS_CFLAGS = @DBUS_CFLAGS@ 150DBUS_CFLAGS = @DBUS_CFLAGS@
151DBUS_LIBS = @DBUS_LIBS@ 151DBUS_LIBS = @DBUS_LIBS@
152## dbusbind.o if HAVE_DBUS, else empty.
152DBUS_OBJ = @DBUS_OBJ@ 153DBUS_OBJ = @DBUS_OBJ@
153 154
154GCONF_CFLAGS = @GCONF_CFLAGS@ 155GCONF_CFLAGS = @GCONF_CFLAGS@
155GCONF_LIBS = @GCONF_LIBS@ 156GCONF_LIBS = @GCONF_LIBS@
156 157
158## gtkutil.o if USE_GTK, else empty.
157GTK_OBJ=@GTK_OBJ@ 159GTK_OBJ=@GTK_OBJ@
158 160
159## -ltermcap, or -lncurses, or -lcurses, or "". 161## -ltermcap, or -lncurses, or -lcurses, or "".
@@ -198,7 +200,10 @@ OLDXMENU_DEPS=@OLDXMENU_DEPS@
198## Else $(OLDXMENU). 200## Else $(OLDXMENU).
199LIBXMENU=@LIBXMENU@ 201LIBXMENU=@LIBXMENU@
200 202
203## xmenu.o if HAVE_X_WINDOWS, else empty.
201XMENU_OBJ=@XMENU_OBJ@ 204XMENU_OBJ=@XMENU_OBJ@
205## xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o
206## xsettings.o xgselect.o if HAVE_X_WINDOWS, else empty.
202XOBJ=@XOBJ@ 207XOBJ=@XOBJ@
203 208
204TOOLKIT_LIBW=@TOOLKIT_LIBW@ 209TOOLKIT_LIBW=@TOOLKIT_LIBW@
@@ -241,7 +246,9 @@ MSDOS_X_OBJ =
241ns_appdir=@ns_appdir@ 246ns_appdir=@ns_appdir@
242ns_appbindir=@ns_appbindir@ 247ns_appbindir=@ns_appbindir@
243ns_appsrc=@ns_appsrc@ 248ns_appsrc=@ns_appsrc@
249## fontset.o fringe.o image.o if HAVE_NS, else empty.
244NS_OBJ=@NS_OBJ@ 250NS_OBJ=@NS_OBJ@
251## nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o if HAVE_NS.
245NS_OBJC_OBJ=@NS_OBJC_OBJ@ 252NS_OBJC_OBJ=@NS_OBJC_OBJ@
246## Only set if NS_IMPL_GNUSTEP. 253## Only set if NS_IMPL_GNUSTEP.
247GNU_OBJC_CFLAGS=@GNU_OBJC_CFLAGS@ 254GNU_OBJC_CFLAGS=@GNU_OBJC_CFLAGS@
@@ -333,12 +340,16 @@ obj = $(base_obj) $(NS_OBJC_OBJ)
333 340
334## Object files used on some machine or other. 341## Object files used on some machine or other.
335## These go in the DOC file on all machines in case they are needed. 342## These go in the DOC file on all machines in case they are needed.
343## Some of them have no DOC entries, but it does no harm to have them
344## in the list, in case they ever add any such entries.
336SOME_MACHINE_OBJECTS = dosfns.o msdos.o \ 345SOME_MACHINE_OBJECTS = dosfns.o msdos.o \
337 xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o fringe.o image.o \ 346 xterm.o xfns.o xmenu.o xselect.o xrdb.o xsmfns.o fringe.o image.o \
338 fontset.o dbusbind.o \ 347 fontset.o dbusbind.o \
339 nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \ 348 nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o \
340 w32.o w32console.o w32fns.o w32heap.o w32inevt.o \ 349 w32.o w32console.o w32fns.o w32heap.o w32inevt.o \
341 w32menu.o w32proc.o w32reg.o w32select.o w32term.o w32xfns.o $(FONT_OBJ) 350 w32menu.o w32proc.o w32reg.o w32select.o w32term.o w32xfns.o \
351 w16select.o widget.o xfont.o ftfont.o xftfont.o ftxfont.o gtkutil.o \
352 xsettings.o xgselect.o termcap.o
342 353
343## gmalloc.o if !SYSTEM_MALLOC && !DOUG_LEA_MALLOC, else empty. 354## gmalloc.o if !SYSTEM_MALLOC && !DOUG_LEA_MALLOC, else empty.
344GMALLOC_OBJ=@GMALLOC_OBJ@ 355GMALLOC_OBJ=@GMALLOC_OBJ@
@@ -411,7 +422,7 @@ emacs$(EXEEXT): temacs$(EXEEXT) $(etc)/DOC $(lisp)
411$(etc)/DOC: $(libsrc)/make-docfile$(EXEEXT) $(obj) $(lisp) 422$(etc)/DOC: $(libsrc)/make-docfile$(EXEEXT) $(obj) $(lisp)
412 -rm -f $(etc)/DOC 423 -rm -f $(etc)/DOC
413 $(libsrc)/make-docfile -d $(srcdir) $(SOME_MACHINE_OBJECTS) $(obj) > $(etc)/DOC 424 $(libsrc)/make-docfile -d $(srcdir) $(SOME_MACHINE_OBJECTS) $(obj) > $(etc)/DOC
414 $(libsrc)/make-docfile -a $(etc)/DOC -d $(srcdir) `sed -n -e 's| \\\\||' -e 's|^[ ]*$$(lispsource)|../lisp|p' $(srcdir)/lisp.mk` 425 $(libsrc)/make-docfile -a $(etc)/DOC -d $(lispsource) `sed -n -e 's| \\\\||' -e 's|^[ ]*$$(lispsource)/||p' $(srcdir)/lisp.mk`
415 426
416$(libsrc)/make-docfile$(EXEEXT): 427$(libsrc)/make-docfile$(EXEEXT):
417 cd $(libsrc); $(MAKE) $(MFLAGS) make-docfile$(EXEEXT) 428 cd $(libsrc); $(MAKE) $(MFLAGS) make-docfile$(EXEEXT)
diff --git a/src/dispnew.c b/src/dispnew.c
index 0457d650b3a..41f486baf16 100644
--- a/src/dispnew.c
+++ b/src/dispnew.c
@@ -4330,23 +4330,29 @@ scrolling_window (struct window *w, int header_line_p)
4330 4330
4331 first_old = first_new = i; 4331 first_old = first_new = i;
4332 4332
4333 /* Set last_new to the index + 1 of the last enabled row in the 4333 /* Set last_new to the index + 1 of the row that reaches the
4334 desired matrix. */ 4334 bottom boundary in the desired matrix. Give up if we find a
4335 disabled row before we reach the bottom boundary. */
4335 i = first_new + 1; 4336 i = first_new + 1;
4336 while (i < desired_matrix->nrows - 1 4337 while (i < desired_matrix->nrows - 1)
4337 && MATRIX_ROW (desired_matrix, i)->enabled_p 4338 {
4338 && MATRIX_ROW_BOTTOM_Y (MATRIX_ROW (desired_matrix, i)) <= yb) 4339 int bottom;
4339 ++i;
4340 4340
4341 if (!MATRIX_ROW (desired_matrix, i)->enabled_p) 4341 if (!MATRIX_ROW (desired_matrix, i)->enabled_p)
4342 return 0; 4342 return 0;
4343 bottom = MATRIX_ROW_BOTTOM_Y (MATRIX_ROW (desired_matrix, i));
4344 if (bottom <= yb)
4345 ++i;
4346 if (bottom >= yb)
4347 break;
4348 }
4343 4349
4344 last_new = i; 4350 last_new = i;
4345 4351
4346 /* Set last_old to the index + 1 of the last enabled row in the 4352 /* Set last_old to the index + 1 of the row that reaches the bottom
4347 current matrix. We don't look at the enabled flag here because 4353 boundary in the current matrix. We don't look at the enabled
4348 we plan to reuse part of the display even if other parts are 4354 flag here because we plan to reuse part of the display even if
4349 disabled. */ 4355 other parts are disabled. */
4350 i = first_old + 1; 4356 i = first_old + 1;
4351 while (i < current_matrix->nrows - 1) 4357 while (i < current_matrix->nrows - 1)
4352 { 4358 {
diff --git a/src/gnutls.c b/src/gnutls.c
index 540bfaac25c..5558fb9ee0b 100644
--- a/src/gnutls.c
+++ b/src/gnutls.c
@@ -221,10 +221,7 @@ init_gnutls_functions (Lisp_Object libraries)
221#define fn_gnutls_record_send gnutls_record_send 221#define fn_gnutls_record_send gnutls_record_send
222#define fn_gnutls_strerror gnutls_strerror 222#define fn_gnutls_strerror gnutls_strerror
223#define fn_gnutls_transport_set_errno gnutls_transport_set_errno 223#define fn_gnutls_transport_set_errno gnutls_transport_set_errno
224#define fn_gnutls_transport_set_lowat gnutls_transport_set_lowat
225#define fn_gnutls_transport_set_ptr2 gnutls_transport_set_ptr2 224#define fn_gnutls_transport_set_ptr2 gnutls_transport_set_ptr2
226#define fn_gnutls_transport_set_pull_function gnutls_transport_set_pull_function
227#define fn_gnutls_transport_set_push_function gnutls_transport_set_push_function
228#define fn_gnutls_x509_crt_check_hostname gnutls_x509_crt_check_hostname 225#define fn_gnutls_x509_crt_check_hostname gnutls_x509_crt_check_hostname
229#define fn_gnutls_x509_crt_deinit gnutls_x509_crt_deinit 226#define fn_gnutls_x509_crt_deinit gnutls_x509_crt_deinit
230#define fn_gnutls_x509_crt_import gnutls_x509_crt_import 227#define fn_gnutls_x509_crt_import gnutls_x509_crt_import
diff --git a/src/xselect.c b/src/xselect.c
index 3ddd4c54b49..c4e9fbf9ff7 100644
--- a/src/xselect.c
+++ b/src/xselect.c
@@ -38,6 +38,7 @@ along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. */
38#include "process.h" 38#include "process.h"
39#include "termhooks.h" 39#include "termhooks.h"
40#include "keyboard.h" 40#include "keyboard.h"
41#include "character.h"
41 42
42#include <X11/Xproto.h> 43#include <X11/Xproto.h>
43 44
@@ -400,17 +401,6 @@ x_get_local_selection (Lisp_Object selection_symbol, Lisp_Object target_type, in
400 handler_fn = Qnil; 401 handler_fn = Qnil;
401 value = XCAR (XCDR (XCDR (local_value))); 402 value = XCAR (XCDR (XCDR (local_value)));
402 } 403 }
403#if 0
404 else if (EQ (target_type, QDELETE))
405 {
406 handler_fn = Qnil;
407 Fx_disown_selection_internal
408 (selection_symbol,
409 XCAR (XCDR (XCDR (local_value))));
410 value = QNULL;
411 }
412#endif
413
414#if 0 /* #### MULTIPLE doesn't work yet */ 404#if 0 /* #### MULTIPLE doesn't work yet */
415 else if (CONSP (target_type) 405 else if (CONSP (target_type)
416 && XCAR (target_type) == QMULTIPLE) 406 && XCAR (target_type) == QMULTIPLE)
@@ -2006,18 +1996,18 @@ x_handle_selection_notify (XSelectionEvent *event)
2006 1996
2007DEFUN ("x-own-selection-internal", Fx_own_selection_internal, 1997DEFUN ("x-own-selection-internal", Fx_own_selection_internal,
2008 Sx_own_selection_internal, 2, 2, 0, 1998 Sx_own_selection_internal, 2, 2, 0,
2009 doc: /* Assert an X selection of the given TYPE with the given VALUE. 1999 doc: /* Assert an X selection of type SELECTION and value VALUE.
2010TYPE is a symbol, typically `PRIMARY', `SECONDARY', or `CLIPBOARD'. 2000SELECTION is a symbol, typically `PRIMARY', `SECONDARY', or `CLIPBOARD'.
2011\(Those are literal upper-case symbol names, since that's what X expects.) 2001\(Those are literal upper-case symbol names, since that's what X expects.)
2012VALUE is typically a string, or a cons of two markers, but may be 2002VALUE is typically a string, or a cons of two markers, but may be
2013anything that the functions on `selection-converter-alist' know about. */) 2003anything that the functions on `selection-converter-alist' know about. */)
2014 (Lisp_Object selection_name, Lisp_Object selection_value) 2004 (Lisp_Object selection, Lisp_Object value)
2015{ 2005{
2016 check_x (); 2006 check_x ();
2017 CHECK_SYMBOL (selection_name); 2007 CHECK_SYMBOL (selection);
2018 if (NILP (selection_value)) error ("SELECTION-VALUE may not be nil"); 2008 if (NILP (value)) error ("VALUE may not be nil");
2019 x_own_selection (selection_name, selection_value); 2009 x_own_selection (selection, value);
2020 return selection_value; 2010 return value;
2021} 2011}
2022 2012
2023 2013
@@ -2056,22 +2046,16 @@ selections. If omitted, defaults to the time for the last event. */)
2056 val = x_get_local_selection (selection_symbol, target_type, 1); 2046 val = x_get_local_selection (selection_symbol, target_type, 1);
2057 2047
2058 if (NILP (val)) 2048 if (NILP (val))
2059 { 2049 RETURN_UNGCPRO (x_get_foreign_selection (selection_symbol,
2060 val = x_get_foreign_selection (selection_symbol, target_type, time_stamp); 2050 target_type, time_stamp));
2061 goto DONE;
2062 }
2063 2051
2064 if (CONSP (val) 2052 if (CONSP (val) && SYMBOLP (XCAR (val)))
2065 && SYMBOLP (XCAR (val)))
2066 { 2053 {
2067 val = XCDR (val); 2054 val = XCDR (val);
2068 if (CONSP (val) && NILP (XCDR (val))) 2055 if (CONSP (val) && NILP (XCDR (val)))
2069 val = XCAR (val); 2056 val = XCAR (val);
2070 } 2057 }
2071 val = clean_local_selection_data (val); 2058 RETURN_UNGCPRO (clean_local_selection_data (val));
2072 DONE:
2073 UNGCPRO;
2074 return val;
2075} 2059}
2076 2060
2077DEFUN ("x-disown-selection-internal", Fx_disown_selection_internal, 2061DEFUN ("x-disown-selection-internal", Fx_disown_selection_internal,
@@ -2651,25 +2635,22 @@ A value of 0 means wait as long as necessary. This is initialized from the
2651 x_selection_timeout = 0; 2635 x_selection_timeout = 0;
2652 2636
2653 /* QPRIMARY is defined in keyboard.c. */ 2637 /* QPRIMARY is defined in keyboard.c. */
2654 QSECONDARY = intern_c_string ("SECONDARY"); staticpro (&QSECONDARY); 2638 DEFSYM (QSECONDARY, "SECONDARY");
2655 QSTRING = intern_c_string ("STRING"); staticpro (&QSTRING); 2639 DEFSYM (QSTRING, "STRING");
2656 QINTEGER = intern_c_string ("INTEGER"); staticpro (&QINTEGER); 2640 DEFSYM (QINTEGER, "INTEGER");
2657 QCLIPBOARD = intern_c_string ("CLIPBOARD"); staticpro (&QCLIPBOARD); 2641 DEFSYM (QCLIPBOARD, "CLIPBOARD");
2658 QTIMESTAMP = intern_c_string ("TIMESTAMP"); staticpro (&QTIMESTAMP); 2642 DEFSYM (QTIMESTAMP, "TIMESTAMP");
2659 QTEXT = intern_c_string ("TEXT"); staticpro (&QTEXT); 2643 DEFSYM (QTEXT, "TEXT");
2660 QCOMPOUND_TEXT = intern_c_string ("COMPOUND_TEXT"); staticpro (&QCOMPOUND_TEXT); 2644 DEFSYM (QCOMPOUND_TEXT, "COMPOUND_TEXT");
2661 QUTF8_STRING = intern_c_string ("UTF8_STRING"); staticpro (&QUTF8_STRING); 2645 DEFSYM (QUTF8_STRING, "UTF8_STRING");
2662 QDELETE = intern_c_string ("DELETE"); staticpro (&QDELETE); 2646 DEFSYM (QDELETE, "DELETE");
2663 QMULTIPLE = intern_c_string ("MULTIPLE"); staticpro (&QMULTIPLE); 2647 DEFSYM (QMULTIPLE, "MULTIPLE");
2664 QINCR = intern_c_string ("INCR"); staticpro (&QINCR); 2648 DEFSYM (QINCR, "INCR");
2665 QEMACS_TMP = intern_c_string ("_EMACS_TMP_"); staticpro (&QEMACS_TMP); 2649 DEFSYM (QEMACS_TMP, "_EMACS_TMP_");
2666 QTARGETS = intern_c_string ("TARGETS"); staticpro (&QTARGETS); 2650 DEFSYM (QTARGETS, "TARGETS");
2667 QATOM = intern_c_string ("ATOM"); staticpro (&QATOM); 2651 DEFSYM (QATOM, "ATOM");
2668 QATOM_PAIR = intern_c_string ("ATOM_PAIR"); staticpro (&QATOM_PAIR); 2652 DEFSYM (QATOM_PAIR, "ATOM_PAIR");
2669 QNULL = intern_c_string ("NULL"); staticpro (&QNULL); 2653 DEFSYM (QNULL, "NULL");
2670 Qcompound_text_with_extensions = intern_c_string ("compound-text-with-extensions"); 2654 DEFSYM (Qcompound_text_with_extensions, "compound-text-with-extensions");
2671 staticpro (&Qcompound_text_with_extensions); 2655 DEFSYM (Qforeign_selection, "foreign-selection");
2672
2673 Qforeign_selection = intern_c_string ("foreign-selection");
2674 staticpro (&Qforeign_selection);
2675} 2656}