osl.c: Dereference pointer _after_ checking for NULL.
authorAndre Noll <maan@systemlinux.org>
Mon, 10 Sep 2007 21:08:35 +0000 (23:08 +0200)
committerAndre Noll <maan@systemlinux.org>
Mon, 10 Sep 2007 21:08:35 +0000 (23:08 +0200)
osl.c

diff --git a/osl.c b/osl.c
index 0ac7ead..54461c1 100644 (file)
--- a/osl.c
+++ b/osl.c
@@ -493,10 +493,10 @@ int init_table_structure(const struct osl_table_description *desc,
        struct osl_table *t = para_calloc(sizeof(*t));
        int i, ret = -E_BAD_TABLE_DESC, have_disk_storage_name_column = 0;
 
-       PARA_INFO_LOG("creating table structure for '%s' from table "
-               "description\n", desc->name);
        if (!desc)
                goto err;
+       PARA_INFO_LOG("creating table structure for '%s' from table "
+               "description\n", desc->name);
        ret = -E_NO_COLUMN_DESC;
        if (!desc->column_descriptions)
                goto err;