diff options
Diffstat (limited to 'src/editfns.c')
| -rw-r--r-- | src/editfns.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/editfns.c b/src/editfns.c index 0c012514f93..360e067a298 100644 --- a/src/editfns.c +++ b/src/editfns.c | |||
| @@ -3240,6 +3240,8 @@ usage: (format STRING &rest OBJECTS) */) | |||
| 3240 | } | 3240 | } |
| 3241 | 3241 | ||
| 3242 | CHECK_STRING (args[0]); | 3242 | CHECK_STRING (args[0]); |
| 3243 | /* We may have to change "%S" to "%s". */ | ||
| 3244 | args[0] = Fcopy_sequence (args[0]); | ||
| 3243 | 3245 | ||
| 3244 | /* If we start out planning a unibyte result, | 3246 | /* If we start out planning a unibyte result, |
| 3245 | and later find it has to be multibyte, we jump back to retry. */ | 3247 | and later find it has to be multibyte, we jump back to retry. */ |
| @@ -3326,6 +3328,11 @@ usage: (format STRING &rest OBJECTS) */) | |||
| 3326 | goto retry; | 3328 | goto retry; |
| 3327 | } | 3329 | } |
| 3328 | args[n] = tem; | 3330 | args[n] = tem; |
| 3331 | /* If we restart the loop, we should not come here again | ||
| 3332 | because args[n] is now a string and calling | ||
| 3333 | Fprin1_to_string on it produces superflous double | ||
| 3334 | quotes. So, change "%S" to "%s" now. */ | ||
| 3335 | *format = 's'; | ||
| 3329 | goto string; | 3336 | goto string; |
| 3330 | } | 3337 | } |
| 3331 | else if (SYMBOLP (args[n])) | 3338 | else if (SYMBOLP (args[n])) |