ONEWAY: fix crash in contrasts when dataset is empty
[pspp] / perl-module / PSPP.xs
index 7577b7ad2c7be4d54b37fad06013aca3d6be0332..dbdc73a106f0311ca6669b49927cca4000aa64fb 100644 (file)
@@ -638,7 +638,7 @@ INIT:
   }
 CODE:
  struct file_handle *fh =
-  fh_create_file (NULL, name, fh_default_properties () );
+   fh_create_file (NULL, name, "UTF-8", fh_default_properties () );
  struct syswriter_info *swi = xmalloc (sizeof (*swi));
  swi->writer = sfm_open_writer (fh, dict->dict, opts);
  swi->dict = dict;
@@ -752,7 +752,7 @@ CODE:
  struct casereader *reader;
  struct sysreader_info *sri = NULL;
  struct file_handle *fh =
-        fh_create_file (NULL, name, fh_default_properties () );
+   fh_create_file (NULL, name, "UTF-8", fh_default_properties () );
  struct dictionary *dict;
 
  sri = xmalloc (sizeof (*sri));