projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
psppire-window: Avoid writing null pointer constant as '\0'.
[pspp]
/
src
/
output
/
driver.c
diff --git
a/src/output/driver.c
b/src/output/driver.c
index 3178878036a167587943077e8d0a184a4dba7722..afb5084fa1d2abc0d76c59d77179fe5a86902b97 100644
(file)
--- a/
src/output/driver.c
+++ b/
src/output/driver.c
@@
-25,7
+25,7
@@
#include <stdlib.h>
#include <string.h>
#include <stdlib.h>
#include <string.h>
-#include "data/file-
name
.h"
+#include "data/file-
handle-def
.h"
#include "data/settings.h"
#include "libpspp/array.h"
#include "libpspp/assertion.h"
#include "data/settings.h"
#include "libpspp/array.h"
#include "libpspp/assertion.h"
@@
-159,6
+159,9
@@
output_submit (struct output_item *item)
{
struct output_engine *e = engine_stack_top ();
{
struct output_engine *e = engine_stack_top ();
+ if (item == NULL)
+ return;
+
if (is_syntax_item (item))
{
ds_put_cstr (&e->deferred_syntax, text_item_get_text (to_text_item (item)));
if (is_syntax_item (item))
{
ds_put_cstr (&e->deferred_syntax, text_item_get_text (to_text_item (item)));
@@
-376,7
+379,9
@@
output_driver_create (struct string_map *options)
device_type = default_device_type (file_name);
}
device_type = default_device_type (file_name);
}
- driver = f->create (file_name, device_type, options);
+ struct file_handle *fh = fh_create_file (NULL, file_name, NULL, fh_default_properties ());
+
+ driver = f->create (fh, device_type, options);
if (driver != NULL)
{
const struct string_map_node *node;
if (driver != NULL)
{
const struct string_map_node *node;