diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/undo.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/undo.c b/src/undo.c index 3d71516e2be..a0e9f84f7c9 100644 --- a/src/undo.c +++ b/src/undo.c | |||
| @@ -123,6 +123,14 @@ record_change (beg, length) | |||
| 123 | record_first_change () | 123 | record_first_change () |
| 124 | { | 124 | { |
| 125 | Lisp_Object high, low; | 125 | Lisp_Object high, low; |
| 126 | |||
| 127 | if (EQ (current_buffer->undo_list, Qt)) | ||
| 128 | return; | ||
| 129 | |||
| 130 | if (current_buffer != XBUFFER (last_undo_buffer)) | ||
| 131 | Fundo_boundary (); | ||
| 132 | XSET (last_undo_buffer, Lisp_Buffer, current_buffer); | ||
| 133 | |||
| 126 | XFASTINT (high) = (current_buffer->modtime >> 16) & 0xffff; | 134 | XFASTINT (high) = (current_buffer->modtime >> 16) & 0xffff; |
| 127 | XFASTINT (low) = current_buffer->modtime & 0xffff; | 135 | XFASTINT (low) = current_buffer->modtime & 0xffff; |
| 128 | current_buffer->undo_list = Fcons (Fcons (Qt, Fcons (high, low)), current_buffer->undo_list); | 136 | current_buffer->undo_list = Fcons (Fcons (Qt, Fcons (high, low)), current_buffer->undo_list); |
| @@ -139,7 +147,7 @@ record_property_change (beg, length, prop, value, buffer) | |||
| 139 | struct buffer *obuf = current_buffer; | 147 | struct buffer *obuf = current_buffer; |
| 140 | int boundary = 0; | 148 | int boundary = 0; |
| 141 | 149 | ||
| 142 | if (EQ (current_buffer->undo_list, Qt)) | 150 | if (EQ (XBUFFER (buffer)->undo_list, Qt)) |
| 143 | return; | 151 | return; |
| 144 | 152 | ||
| 145 | if (!EQ (buffer, last_undo_buffer)) | 153 | if (!EQ (buffer, last_undo_buffer)) |