summaryrefslogtreecommitdiff
path: root/src/syntax.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/syntax.c')
-rw-r--r--src/syntax.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/syntax.c b/src/syntax.c
index 4ab87a3a3c2..b17a8d4d0bc 100644
--- a/src/syntax.c
+++ b/src/syntax.c
@@ -877,8 +877,8 @@ DEFUN ("modify-syntax-entry", Fmodify_syntax_entry, Smodify_syntax_entry, 2, 3,
if (*p)
{
int len;
- int character = STRING_CHAR_AND_LENGTH (p, XSTRING (newentry)->size - 1,
- len);
+ int character = (STRING_CHAR_AND_LENGTH
+ (p, STRING_BYTES (XSTRING (newentry)) - 1, len));
XSETINT (match, character);
if (XFASTINT (match) == ' ')
match = Qnil;