aboutsummaryrefslogtreecommitdiffstats
path: root/src/doc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/doc.c')
-rw-r--r--src/doc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/doc.c b/src/doc.c
index 1ddaa117bb..7234fb38bf 100644
--- a/src/doc.c
+++ b/src/doc.c
@@ -826,7 +826,7 @@ Otherwise, return a new string, without any text properties. */)
if (NILP (tem)) /* but not on any keys */
{
ptrdiff_t offset = bufp - buf;
- if (bsize > STRING_BYTES_BOUND - 4)
+ if (STRING_BYTES_BOUND - 4 < bsize)
string_overflow ();
buf = xrealloc (buf, bsize += 4);
bufp = buf + offset;