From 02bc765f3cee0217b003270c556efcdf08938549 Mon Sep 17 00:00:00 2001 From: "Jon A. Cruz" Date: Tue, 23 Mar 2010 00:32:40 -0700 Subject: [PATCH] Add needed null check. --- src/widgets/swatch-selector.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/widgets/swatch-selector.cpp b/src/widgets/swatch-selector.cpp index 602adec4f..a6f5133b7 100644 --- a/src/widgets/swatch-selector.cpp +++ b/src/widgets/swatch-selector.cpp @@ -108,7 +108,7 @@ void SwatchSelector::_changedCb(SPColorSelector */*csel*/, void *data) // TODO might have to block cycles - if (swsel->_gsel) { + if (swsel->_gsel && swsel->_gsel->getVector()) { SPGradient *gradient = swsel->_gsel->getVector(); SPGradient *ngr = sp_gradient_ensure_vector_normalized(gradient); if (ngr != gradient) { -- 2.30.2