comparison th_ioctx.h @ 693:a622d21833e1

Implement fopen() in mem ioctx, and simplistic read-only/write flag support.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 09 Mar 2020 18:54:37 +0200
parents dfc2c9f0577f
children 0fc5ddaccc57
comparison
equal deleted inserted replaced
692:ea6bcbfb9d18 693:a622d21833e1
47 size_t memSize; ///< Size of data 47 size_t memSize; ///< Size of data
48 size_t memAlloc; ///< Amount allocated 48 size_t memAlloc; ///< Amount allocated
49 size_t minAlloc; ///< Minimum allocation increase (0 = default) 49 size_t minAlloc; ///< Minimum allocation increase (0 = default)
50 off_t memOffset; ///< Current offset in data 50 off_t memOffset; ///< Current offset in data
51 uint8_t *memData; ///< Pointer to data 51 uint8_t *memData; ///< Pointer to data
52 BOOL memWrite; ///< TRUE = memory can be written to / expanded etc. FALSE = no
52 53
53 // Message functions 54 // Message functions
54 void (*error)(struct th_ioctx *ctx, const int err, const char *msg); 55 void (*error)(struct th_ioctx *ctx, const int err, const char *msg);
55 void (*msg)(struct th_ioctx *ctx, const int level, const char *msg); 56 void (*msg)(struct th_ioctx *ctx, const int level, const char *msg);
56 57