~ubuntu-branches/ubuntu/utopic/fftw3/utopic

« back to all changes in this revision

Viewing changes to api/export-wisdom-to-file.c

  • Committer: Package Import Robot
  • Author(s): Matthias Klose
  • Date: 2011-12-14 13:21:22 UTC
  • mfrom: (3.1.5 sid)
  • Revision ID: package-import@ubuntu.com-20111214132122-l4avyl2kkr7vq5aj
Tags: 3.3-1ubuntu1
* Merge with Debian; remaining changes:
  - Revert the ARM workaround.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/*
2
 
 * Copyright (c) 2003, 2007-8 Matteo Frigo
3
 
 * Copyright (c) 2003, 2007-8 Massachusetts Institute of Technology
 
2
 * Copyright (c) 2003, 2007-11 Matteo Frigo
 
3
 * Copyright (c) 2003, 2007-11 Massachusetts Institute of Technology
4
4
 *
5
5
 * This program is free software; you can redistribute it and/or modify
6
6
 * it under the terms of the GNU General Public License as published by
27
27
     plnr->adt->exprt(plnr, p);
28
28
     X(printer_destroy)(p);
29
29
}
 
30
 
 
31
int X(export_wisdom_to_filename)(const char *filename)
 
32
{
 
33
     FILE *f = fopen(filename, "w");
 
34
     int ret;
 
35
     if (!f) return 0; /* error opening file */
 
36
     X(export_wisdom_to_file)(f);
 
37
     ret = !ferror(f);
 
38
     if (fclose(f)) ret = 0; /* error closing file */
 
39
     return ret;
 
40
}