From 6cc4e9f6f390277b7dd95be2cbbbbb4d4f68a87c Mon Sep 17 00:00:00 2001 From: Pako Smith Date: Thu, 15 Nov 2018 13:57:41 +0300 Subject: [PATCH] [CMD] Fix Coverity #715934 "Copy-paste error" (#1040) Fix linked-list pointer comparison. --- base/shell/cmd/history.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/base/shell/cmd/history.c b/base/shell/cmd/history.c index e6676a7ffdd..3c709a7ecf0 100644 --- a/base/shell/cmd/history.c +++ b/base/shell/cmd/history.c @@ -309,7 +309,7 @@ LPCTSTR PeekHistory(INT dir) else { /* key down */ - if (entry->next == Bottom || entry == Bottom) + if (entry->prev == Bottom || entry == Bottom) { #ifdef WRAP_HISTORY entry = Top;