]> git.lyx.org Git - features.git/commitdiff
Fix null pointer warnings.
authorRichard Kimberly Heck <rikiheck@lyx.org>
Thu, 27 Feb 2020 05:05:41 +0000 (00:05 -0500)
committerRichard Kimberly Heck <rikiheck@lyx.org>
Thu, 27 Feb 2020 05:05:41 +0000 (00:05 -0500)
src/frontends/qt/TocWidget.cpp

index dcd9c4d0e50420b61595f859bb3ec86773ff4640..7a13d9d684e0482e48922799cc92b1d3048d31dc 100644 (file)
@@ -118,7 +118,7 @@ Inset * TocWidget::itemInset() const
                gui_view_.tocModels().currentItem(current_type_, index);
        DocIterator const & dit = item.dit();
 
-       Inset * inset = 0;
+       Inset * inset = nullptr;
        if (current_type_ == "label"
                  || current_type_ == "graphics"
                  || current_type_ == "citation"
@@ -408,7 +408,7 @@ void TocWidget::enableControls(bool enable)
 void TocWidget::updateView()
 {
        if (!gui_view_.documentBufferView()) {
-               tocTV->setModel(0);
+               tocTV->setModel(nullptr);
                depthSL->setMaximum(0);
                depthSL->setValue(0);
                setEnabled(false);