]> granicus.if.org Git - neomutt/commitdiff
lua: fix command-line processing
authorRichard Russon <rich@flatcap.org>
Tue, 26 Mar 2019 12:07:11 +0000 (12:07 +0000)
committerRichard Russon <rich@flatcap.org>
Tue, 26 Mar 2019 17:46:29 +0000 (17:46 +0000)
The 'lua' command uses the entire line of text.
Clear the Buffer so that NeoMutt doesn't try to interpret it.

Fixes #1610

mutt_lua.c

index 8baa777e1b323e2db94f14501d26c69d178cdf44..6e222ff0890b47aa8bc9caaeba8b4f1e719fc8f8 100644 (file)
@@ -459,6 +459,7 @@ enum CommandResult mutt_lua_parse(struct Buffer *buf, struct Buffer *s,
     return MUTT_CMD_ERROR;
   }
   mutt_debug(LL_DEBUG2, " * %s -> success\n", s->dptr);
+  mutt_buffer_reset(s); // Clear the rest of the line
   return MUTT_CMD_SUCCESS;
 }