From f97a803f8177d0efc376bb17db82afdc9fb1e6ef Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 30 May 2014 19:53:29 -0700 Subject: [PATCH] * src/cmds.c (Fself_insert_command): Allow zero repeat count. --- src/ChangeLog | 4 ++++ src/cmds.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 927d6662c67..f09729cbb8a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2014-05-31 Glenn Morris + + * cmds.c (Fself_insert_command): Allow zero repeat count. (Bug#17649) + 2014-05-30 Paul Eggert Fix port to 32-bit AIX with xlc (Bug#17598). diff --git a/src/cmds.c b/src/cmds.c index 7459908828d..1a510afa271 100644 --- a/src/cmds.c +++ b/src/cmds.c @@ -280,8 +280,8 @@ At the end, it runs `post-self-insert-hook'. */) bool remove_boundary = 1; CHECK_NUMBER (n); - if (XFASTINT (n) < 1) - error ("Nonpositive repetition argument %"pI"d", XFASTINT (n)); + if (XFASTINT (n) < 0) + error ("Negative repetition argument %"pI"d", XFASTINT (n)); if (!EQ (Vthis_command, KVAR (current_kboard, Vlast_command))) nonundocount = 0; -- 2.11.4.GIT