From: John Darrington Date: Mon, 6 Jul 2009 17:38:21 +0000 (+0800) Subject: Fix crash when opening empty dataset X-Git-Tag: build37~53^2~21 X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1485e3a189c42b1ac1339c063c85d9e74e503431;p=pspp-builds.git Fix crash when opening empty dataset --- diff --git a/src/ui/gui/psppire-data-store.c b/src/ui/gui/psppire-data-store.c index 07795124..65001dd1 100644 --- a/src/ui/gui/psppire-data-store.c +++ b/src/ui/gui/psppire-data-store.c @@ -801,6 +801,9 @@ get_column_button_label (const PsppireSheetModel *model, gint col) pv = psppire_dict_get_variable (ds->dict, col); + if (NULL == pv) + return NULL; + return xstrdup (var_get_name (pv)); }