Blame gl/read-file.h

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