Blame src/gl/read-file.h

Packit aea12f
/* read-file.h -- read file contents into a string
Packit Service 991b93
   Copyright (C) 2006, 2009-2020 Free Software Foundation, Inc.
Packit aea12f
   Written by Simon Josefsson.
Packit aea12f
Packit aea12f
   This program is free software; you can redistribute it and/or modify
Packit aea12f
   it under the terms of the GNU General Public License as published by
Packit aea12f
   the Free Software Foundation; either version 3, or (at your option)
Packit aea12f
   any later version.
Packit aea12f
Packit aea12f
   This program is distributed in the hope that it will be useful,
Packit aea12f
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit aea12f
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
Packit aea12f
   GNU General Public License for more details.
Packit aea12f
Packit aea12f
   You should have received a copy of the GNU General Public License
Packit aea12f
   along with this program; if not, see <https://www.gnu.org/licenses/>.  */
Packit aea12f
Packit aea12f
#ifndef READ_FILE_H
Packit aea12f
#define READ_FILE_H
Packit aea12f
Packit aea12f
/* Get size_t.  */
Packit aea12f
#include <stddef.h>
Packit aea12f
Packit aea12f
/* Get FILE.  */
Packit aea12f
#include <stdio.h>
Packit aea12f
Packit Service 991b93
/* Indicate that the file is treated as binary.  */
Packit Service 991b93
#define RF_BINARY 0x1
Packit aea12f
Packit Service 991b93
/* Indicate that the file content contains sensitive information.  */
Packit Service 991b93
#define RF_SENSITIVE 0x2
Packit aea12f
Packit Service 991b93
extern char *fread_file (FILE * stream, int flags, size_t * length);
Packit Service 991b93
Packit Service 991b93
extern char *read_file (const char *filename, int flags, size_t * length);
Packit aea12f
Packit aea12f
#endif /* READ_FILE_H */