From 5145694cd067e221a661e0d6c7dce4ed5ca22e37 Mon Sep 17 00:00:00 2001 From: Jean-Marc Lasgouttes Date: Fri, 29 Jan 2021 18:29:55 +0100 Subject: [PATCH] No need to set background color of a newly created branch. Fixes a null pointer dereference spotted by coverity. --- src/Buffer.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/Buffer.cpp b/src/Buffer.cpp index c46dab75ba..baed1d4239 100644 --- a/src/Buffer.cpp +++ b/src/Buffer.cpp @@ -2943,8 +2943,6 @@ void Buffer::dispatch(FuncRequest const & func, DispatchResult & dr) } else { undo().recordUndoBufferParams(CursorData()); branch_list.add(branch_name); - branch = branch_list.find(branch_name); - branch->setColors("background", "background"); dr.setError(false); dr.screenUpdate(Update::Force); } -- 2.39.5