commit 5145694cd067e221a661e0d6c7dce4ed5ca22e37
Author: Jean-Marc Lasgouttes <lasgout...@lyx.org>
Date:   Fri Jan 29 18:29:55 2021 +0100

    No need to set background color of a newly created branch.
    
    Fixes a null pointer dereference spotted by coverity.
---
 src/Buffer.cpp |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/src/Buffer.cpp b/src/Buffer.cpp
index c46dab7..baed1d4 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);
                        }
-- 
lyx-cvs mailing list
lyx-cvs@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to