diff options
| author | Gerd Moellmann | 2000-12-04 15:54:41 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-12-04 15:54:41 +0000 |
| commit | d7f31e224bfa16fddde4288a8e31fd0f8001935d (patch) | |
| tree | d71dedd62b7e4f5d560e5ef88821341d1092a2b1 | |
| parent | ae18aa3b610f1de4fe2b81595090deedefe6f836 (diff) | |
| download | emacs-d7f31e224bfa16fddde4288a8e31fd0f8001935d.tar.gz emacs-d7f31e224bfa16fddde4288a8e31fd0f8001935d.zip | |
(auto_save_error): Add parameter ERROR. Show the
error in the message.
| -rw-r--r-- | src/ChangeLog | 3 | ||||
| -rw-r--r-- | src/fileio.c | 31 |
2 files changed, 27 insertions, 7 deletions
diff --git a/src/ChangeLog b/src/ChangeLog index e484ffed576..ece9b428aa1 100644 --- a/src/ChangeLog +++ b/src/ChangeLog | |||
| @@ -1,5 +1,8 @@ | |||
| 1 | 2000-12-04 Gerd Moellmann <gerd@gnu.org> | 1 | 2000-12-04 Gerd Moellmann <gerd@gnu.org> |
| 2 | 2 | ||
| 3 | * fileio.c (auto_save_error): Add parameter ERROR. Show the | ||
| 4 | error in the message. | ||
| 5 | |||
| 3 | * keyboard.c (Fread_key_sequence): Don't start the busy cursor | 6 | * keyboard.c (Fread_key_sequence): Don't start the busy cursor |
| 4 | timer after having read a key. It's not good for code reading | 7 | timer after having read a key. It's not good for code reading |
| 5 | several keys in a loop, like an input method. | 8 | several keys in a loop, like an input method. |
diff --git a/src/fileio.c b/src/fileio.c index 0eb07ce3bc1..92a4842391c 100644 --- a/src/fileio.c +++ b/src/fileio.c | |||
| @@ -5224,15 +5224,32 @@ An argument specifies the modification time value to use\n\ | |||
| 5224 | } | 5224 | } |
| 5225 | 5225 | ||
| 5226 | Lisp_Object | 5226 | Lisp_Object |
| 5227 | auto_save_error () | 5227 | auto_save_error (error) |
| 5228 | Lisp_Object error; | ||
| 5228 | { | 5229 | { |
| 5230 | Lisp_Object args[3], msg; | ||
| 5231 | int i, nbytes; | ||
| 5232 | struct gcpro gcpro1; | ||
| 5233 | |||
| 5229 | ring_bell (); | 5234 | ring_bell (); |
| 5230 | message_with_string ("Autosaving...error for %s", current_buffer->name, 1); | 5235 | |
| 5231 | Fsleep_for (make_number (1), Qnil); | 5236 | args[0] = build_string ("Auto-saving %s: %s"); |
| 5232 | message_with_string ("Autosaving...error for %s", current_buffer->name, 0); | 5237 | args[1] = current_buffer->name; |
| 5233 | Fsleep_for (make_number (1), Qnil); | 5238 | args[2] = Ferror_message_string (error); |
| 5234 | message_with_string ("Autosaving...error for %s", current_buffer->name, 0); | 5239 | msg = Fformat (3, args); |
| 5235 | Fsleep_for (make_number (1), Qnil); | 5240 | GCPRO1 (msg); |
| 5241 | nbytes = STRING_BYTES (XSTRING (msg)); | ||
| 5242 | |||
| 5243 | for (i = 0; i < 3; ++i) | ||
| 5244 | { | ||
| 5245 | if (i == 0) | ||
| 5246 | message2 (XSTRING (msg)->data, nbytes, STRING_MULTIBYTE (msg)); | ||
| 5247 | else | ||
| 5248 | message2_nolog (XSTRING (msg)->data, nbytes, STRING_MULTIBYTE (msg)); | ||
| 5249 | Fsleep_for (make_number (1), Qnil); | ||
| 5250 | } | ||
| 5251 | |||
| 5252 | UNGCPRO; | ||
| 5236 | return Qnil; | 5253 | return Qnil; |
| 5237 | } | 5254 | } |
| 5238 | 5255 | ||