render: Fix up layer violation in add_footnote_page().
[pspp] / src / output / table.c
index 2fa40c9091fda608304757134f70ed819b07b3a7..a4730f85e5a3219c0ed67acc2139cf2fb68c9bca 100644 (file)
@@ -644,6 +644,8 @@ struct footnote *
 table_create_footnote (struct table *table, size_t idx, const char *content,
                      const char *marker, struct area_style *style)
 {
+  assert (style);
+
   struct footnote *f = pool_alloc (table->container, sizeof *f);
   f->idx = idx;
   f->content = pool_strdup (table->container, content);
@@ -654,8 +656,10 @@ table_create_footnote (struct table *table, size_t idx, const char *content,
 
 void
 table_add_footnote (struct table *table, int x, int y,
-                  const struct footnote *f)
+                    const struct footnote *f)
 {
+  assert (f->style);
+
   int index = x + y * table_nc (table);
   unsigned short opt = table->ct[index];
   struct table_joined_cell *j;