From: Paul Eggert Date: Sun, 22 Apr 2012 04:35:17 +0000 (-0700) Subject: * print.c: (print_depth, new_backquote_output, print_number_index): X-Git-Tag: emacs-24.2.90~471^2~6^2~112 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a8b7caa345d8215468f558c771b703a3b89e2d77;p=emacs.git * print.c: (print_depth, new_backquote_output, print_number_index): Use ptrdiff_t, not int, where int might not be wide enough. --- diff --git a/src/ChangeLog b/src/ChangeLog index 0504fb006a3..336c175be5c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -559,6 +559,8 @@ (Fexternal_debugging_output): Don't overflow EMACS_INT->int conversion. (print_error_message): Use SAFE_ALLOCA, not alloca. (print_object): Use int, not EMACS_INT, where int is wide enough. + (print_depth, new_backquote_output, print_number_index): + Use ptrdiff_t, not int, where int might not be wide enough. * process.c (Fdelete_process): Don't assume pid fits into EMACS_INT. (Fset_process_window_size, Fformat_network_address) (get_lisp_to_sockaddr_size, set_socket_option, Fmake_network_process) diff --git a/src/print.c b/src/print.c index 92e62520954..bfe3287b92c 100644 --- a/src/print.c +++ b/src/print.c @@ -55,10 +55,10 @@ static Lisp_Object Qfloat_output_format; #endif /* Avoid actual stack overflow in print. */ -static int print_depth; +static ptrdiff_t print_depth; /* Level of nesting inside outputting backquote in new style. */ -static int new_backquote_output; +static ptrdiff_t new_backquote_output; /* Detect most circularities to print finite output. */ #define PRINT_CIRCLE 200 @@ -86,7 +86,7 @@ static Lisp_Object Qprint_escape_multibyte, Qprint_escape_nonascii; N the object has been printed so we can refer to it as #N#. print_number_index holds the largest N already used. N has to be striclty larger than 0 since we need to distinguish -N. */ -static int print_number_index; +static ptrdiff_t print_number_index; static void print_interval (INTERVAL interval, Lisp_Object printcharfun); /* GDB resets this to zero on W32 to disable OutputDebugString calls. */