diff --git a/server/console.c b/server/console.c index efb20daed45..4d275f08e2a 100644 --- a/server/console.c +++ b/server/console.c @@ -1055,7 +1055,7 @@ static void console_input_append_hist( struct console_input* console, const WCHA ptr[len] = 0; if (console->history_mode && console->history_index && - strncmpW( console->history[console->history_index - 1], ptr, len ) == 0) + !strcmpW( console->history[console->history_index - 1], ptr )) { /* ok, mode ask us to not use twice the same string... * so just free mem and returns