aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Eggert2011-10-24 15:56:06 -0700
committerPaul Eggert2011-10-24 15:56:06 -0700
commitee7804014888b29a0f75330ab305419a647925bb (patch)
tree9a0eebd27971162ea73369e753d4a795c069829b /src
parent6efdadfdbad817826a8c311f5e3fae449bcf0471 (diff)
downloademacs-ee7804014888b29a0f75330ab305419a647925bb.tar.gz
emacs-ee7804014888b29a0f75330ab305419a647925bb.zip
* print.c (PRINTFINISH): Undo alloca change; not needed.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog1
-rw-r--r--src/print.c6
2 files changed, 2 insertions, 5 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 8e2ef5e0eb2..c288ed6a2ed 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -553,7 +553,6 @@
553 (temp_output_buffer_setup, Fprin1_to_string, print_object): 553 (temp_output_buffer_setup, Fprin1_to_string, print_object):
554 Use ptrdiff_t, not int, to avoid needless 32-bit limit on 64-bit hosts. 554 Use ptrdiff_t, not int, to avoid needless 32-bit limit on 64-bit hosts.
555 (PRINTPREPARE): Use int, not ptrdiff_t, where int is wide enough. 555 (PRINTPREPARE): Use int, not ptrdiff_t, where int is wide enough.
556 (PRINTFINISH): Use SAFE_ALLOCA, not alloca.
557 (printchar, strout): Use xpalloc to catch size calculation overflow. 556 (printchar, strout): Use xpalloc to catch size calculation overflow.
558 (Fexternal_debugging_output): Use CHECK_CHARACTER, not CHECK_NUMBER, 557 (Fexternal_debugging_output): Use CHECK_CHARACTER, not CHECK_NUMBER,
559 to avoid mishandling large integers. 558 to avoid mishandling large integers.
diff --git a/src/print.c b/src/print.c
index 8e5aab85c3c..63ef3e6279e 100644
--- a/src/print.c
+++ b/src/print.c
@@ -173,14 +173,12 @@ int print_output_debug_flag EXTERNALLY_VISIBLE = 1;
173 if (print_buffer_pos != print_buffer_pos_byte \ 173 if (print_buffer_pos != print_buffer_pos_byte \
174 && NILP (BVAR (current_buffer, enable_multibyte_characters))) \ 174 && NILP (BVAR (current_buffer, enable_multibyte_characters))) \
175 { \ 175 { \
176 USE_SAFE_ALLOCA; \ 176 unsigned char *temp \
177 unsigned char *temp; \ 177 = (unsigned char *) alloca (print_buffer_pos + 1); \
178 SAFE_ALLOCA (temp, unsigned char *, print_buffer_pos + 1); \
179 copy_text ((unsigned char *) print_buffer, temp, \ 178 copy_text ((unsigned char *) print_buffer, temp, \
180 print_buffer_pos_byte, 1, 0); \ 179 print_buffer_pos_byte, 1, 0); \
181 insert_1_both ((char *) temp, print_buffer_pos, \ 180 insert_1_both ((char *) temp, print_buffer_pos, \
182 print_buffer_pos, 0, 1, 0); \ 181 print_buffer_pos, 0, 1, 0); \
183 SAFE_FREE (); \
184 } \ 182 } \
185 else \ 183 else \
186 insert_1_both (print_buffer, print_buffer_pos, \ 184 insert_1_both (print_buffer, print_buffer_pos, \