src/doprnt.c (doprnt): Don't return value smaller than the buffer
size if the message was truncated. (Bug#8545).
+2011-04-28 Eli Zaretskii <eliz@gnu.org>
+
+ * doprnt.c (doprnt): Don't return value smaller than the buffer
+ size if the message was truncated. (Bug#8545).
+
2011-04-28 Juanma Barranquero <lekktu@gmail.com>
* w32fns.c (Fx_change_window_property, Fx_delete_window_property)
while (fmt < format_end && --bufsize > 0 && !CHAR_HEAD_P (*fmt));
if (!CHAR_HEAD_P (*fmt))
{
- bufptr = save_bufptr;
+ /* Truncate, but return value that will signal to caller
+ that the buffer was too small. */
+ *save_bufptr = 0;
break;
}
}