switch to using FILE * in the reader

This commit is contained in:
krangelov
2021-09-15 08:06:18 +02:00
parent 9fe6ee3cce
commit c6d6914688
4 changed files with 37 additions and 32 deletions

View File

@@ -1,8 +1,6 @@
#ifndef READER_H_
#define READER_H_
#include <fstream>
#include <stdint.h>
#include "db.h"
// reader for PGF files
@@ -10,7 +8,7 @@
class PGF_INTERNAL_DECL PgfReader
{
public:
PgfReader(std::istream *in, const char *filepath);
PgfReader(FILE *in, const char *filepath);
uint8_t read_uint8();
uint16_t read_u16be();
@@ -73,7 +71,7 @@ public:
ref<PgfPGF> read_pgf();
private:
std::istream *in;
FILE *in;
const char* filepath;
object read_name_internal(size_t struct_size);