Loading...
Searching...
No Matches
vcdiff_vfs.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2022 Juergen Fitschen
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
9#pragma once
10
19
20#include "vcdiff.h"
21#include "vfs.h"
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
30extern const vcdiff_driver_t vcdiff_vfs_driver;
31
35typedef struct {
36 int fd;
37 size_t max_size;
39
43#define VCDIFF_VFS_INIT_MAX_SIZE(FD, SIZE) { .fd = FD, .max_size = SIZE }
44
48#define VCDIFF_VFS_INIT(FD) VCDIFF_VFS_INIT_MAX_SIZE(FD, SIZE_MAX)
49
50#ifdef __cplusplus
51}
52#endif
53
Context for the underlying file.
Definition vcdiff_vfs.h:35
size_t max_size
Maximum file size for vcdiff target files.
Definition vcdiff_vfs.h:37
int fd
File descriptor of the VFS file.
Definition vcdiff_vfs.h:36
const vcdiff_driver_t vcdiff_vfs_driver
Driver for accessing VFS-based file access.