From: cloudwalk Date: Sun, 24 Jan 2021 02:23:33 +0000 (+0000) Subject: keys: Fix intermittent buffer overflow when pasting text. From malice X-Git-Url: https://git.xonotic.org/?a=commitdiff_plain;ds=sidebyside;h=6c3cfd667f00484beee8b27d663a55cd6b53b43b;p=xonotic%2Fdarkplaces.git keys: Fix intermittent buffer overflow when pasting text. From malice git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@13092 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/keys.c b/keys.c index 3038eba6..d830e827 100644 --- a/keys.c +++ b/keys.c @@ -782,7 +782,8 @@ int Key_Parse_CommonKeys(cmd_state_t *cmd, qbool is_console, int key, int unicod } else if (*p == '\n' || *p == '\r' || *p == '\b') *p++ = ';'; - p++; + else + p++; } #else strtok(cbd, "\n\r\b");