summaryrefslogtreecommitdiffstats
path: root/src/cc4group.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/cc4group.h')
-rw-r--r--src/cc4group.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/cc4group.h b/src/cc4group.h
index 0a3ceb4..780c50e 100644
--- a/src/cc4group.h
+++ b/src/cc4group.h
@@ -140,10 +140,12 @@ typedef void* (*CC4Group_TmpMemoryStrategy)(CC4Group* const this, const size_t s
// actually, a memory management strategy is a pointer to an instance of this struct
// it consists of a start function (like allocating some memory and making a copy)
// and of an end function, which does the actual cleanup
+// and an optional custom arg that will be passed to both functions
// additionally to the predefined memory management strategies, custom strategies may be used
typedef struct {
- void* (*start)(void* const data, const size_t size);
- void (*end)(void* const data);
+ void* (*start)(void* const data, const size_t size, void* const arg);
+ void (*end)(void* const data, void* const arg);
+ void* arg;
} const CC4Group_MemoryManagement_t;
typedef CC4Group_MemoryManagement_t* CC4Group_MemoryManagement;