diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2011-07-17 22:34:14 -0400 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2011-07-17 22:34:14 -0400 |
commit | 925a6be733dc81bd5295680b9c10e3a373d5f9b8 (patch) | |
tree | de8e6a325c77b97b8c0b94e8260c15432c3fe5a5 | |
parent | 6265325e6bc5ed7da0e049f1b6e148932ea69e34 (diff) | |
download | emacs-925a6be733dc81bd5295680b9c10e3a373d5f9b8.tar.gz |
* src/xdisp.c (next_element_from_string, next_element_from_buffer): Use EQ
to compare Lisp_Objects.
* src/gnutls.c (syms_of_gnutls): Rename Vgnutls_log_level to
global_gnutls_log_level, don't mistake it for a Lisp_Object.
(init_gnutls_functions, emacs_gnutls_handle_error): Fix up uses.
-rw-r--r-- | src/ChangeLog | 8 | ||||
-rw-r--r-- | src/gnutls.c | 12 | ||||
-rw-r--r-- | src/process.h | 2 | ||||
-rw-r--r-- | src/xdisp.c | 4 |
4 files changed, 16 insertions, 10 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index c06c98c5418..a2891fa9c91 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,11 @@ +2011-07-18 Stefan Monnier <monnier@iro.umontreal.ca> + + * xdisp.c (next_element_from_string, next_element_from_buffer): Use EQ + to compare Lisp_Objects. + * gnutls.c (syms_of_gnutls): Rename Vgnutls_log_level to + global_gnutls_log_level, don't mistake it for a Lisp_Object. + (init_gnutls_functions, emacs_gnutls_handle_error): Fix up uses. + 2011-07-17 Andreas Schwab <schwab@linux-m68k.org> * lread.c (read_integer): Unread even EOF character. diff --git a/src/gnutls.c b/src/gnutls.c index 52e80a69ae5..3175f55041d 100644 --- a/src/gnutls.c +++ b/src/gnutls.c @@ -193,8 +193,7 @@ init_gnutls_functions (Lisp_Object libraries) LOAD_GNUTLS_FN (library, gnutls_x509_crt_import); LOAD_GNUTLS_FN (library, gnutls_x509_crt_init); - if (NUMBERP (Vgnutls_log_level)) - max_log_level = XINT (Vgnutls_log_level); + max_log_level = global_gnutls_log_level; GNUTLS_LOG2 (1, max_log_level, "GnuTLS library loaded:", SDATA (Fget (Qgnutls_dll, QCloaded_from))); @@ -406,8 +405,7 @@ emacs_gnutls_handle_error (gnutls_session_t session, int err) if (err >= 0) return 0; - if (NUMBERP (Vgnutls_log_level)) - max_log_level = XINT (Vgnutls_log_level); + max_log_level = global_gnutls_log_level; /* TODO: use gnutls-error-fatalp and gnutls-error-string. */ @@ -1155,9 +1153,9 @@ syms_of_gnutls (void) defsubr (&Sgnutls_bye); defsubr (&Sgnutls_available_p); - DEFVAR_INT ("gnutls-log-level", Vgnutls_log_level, - doc: /* Logging level used by the GnuTLS functions. */); - Vgnutls_log_level = make_number (0); + DEFVAR_INT ("gnutls-log-level", global_gnutls_log_level, + doc: /* Logging level used by the GnuTLS functions. */); + global_gnutls_log_level = 0; } #endif /* HAVE_GNUTLS */ diff --git a/src/process.h b/src/process.h index 4866a8c1022..aff9e970f63 100644 --- a/src/process.h +++ b/src/process.h @@ -141,7 +141,7 @@ struct Lisp_Process /* Every field in the preceding structure except for the first two must be a Lisp_Object, for GC's sake. */ -#define ChannelMask(n) (1<<(n)) +#define ChannelMask(n) (1 << (n)) /* True if we are about to fork off a synchronous process or if we are waiting for it. */ diff --git a/src/xdisp.c b/src/xdisp.c index 50da62ca0ab..72a246ca0c3 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -6945,7 +6945,7 @@ next_element_from_string (struct it *it) struct text_pos position; xassert (STRINGP (it->string)); - xassert (!it->bidi_p || it->string == it->bidi_it.string.lstring); + xassert (!it->bidi_p || EQ (it->string, it->bidi_it.string.lstring)); xassert (IT_STRING_CHARPOS (*it) >= 0); position = it->current.string_pos; @@ -7259,7 +7259,7 @@ next_element_from_buffer (struct it *it) xassert (IT_CHARPOS (*it) >= BEGV); xassert (NILP (it->string) && !it->s); xassert (!it->bidi_p - || (it->bidi_it.string.lstring == Qnil + || (EQ (it->bidi_it.string.lstring, Qnil) && it->bidi_it.string.s == NULL)); /* With bidi reordering, the character to display might not be the |