diff options
author | Christoph Reiter <reiter.christoph@gmail.com> | 2018-12-06 09:01:02 +0100 |
---|---|---|
committer | Christoph Reiter <reiter.christoph@gmail.com> | 2018-12-06 09:57:58 +0000 |
commit | 953b45b14e2749be239ff3fdb0040998106d6758 (patch) | |
tree | e9a988226cbe56f8bee67734327c18e3fb3e7bda /giscanner/sourcescanner.py | |
parent | aaa7af50f98771efc8172c5dff7a898feda8c423 (diff) | |
download | gobject-introspection-953b45b14e2749be239ff3fdb0040998106d6758.tar.gz |
gi_source_scanner_parse_file: use a filename instead of a FILE struct
This allows us to get rid of the msvc hacks which are needed in case Python
is built with a different msvc than g-i. By passing a filename the FILE struct never
passes over library boundaries.
Diffstat (limited to 'giscanner/sourcescanner.py')
-rw-r--r-- | giscanner/sourcescanner.py | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/giscanner/sourcescanner.py b/giscanner/sourcescanner.py index aea05e65..d867a4e9 100644 --- a/giscanner/sourcescanner.py +++ b/giscanner/sourcescanner.py @@ -307,10 +307,7 @@ class SourceScanner(object): self._cpp_options) os.unlink(tmp_name_cpp) - fp = open(tmpfile_output, 'r') - - self._scanner.parse_file(fp.fileno()) - fp.close() + self._scanner.parse_file(tmpfile_output) os.unlink(tmpfile_output) def _write_preprocess_src(self, fp, defines, undefs, filenames): |