diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2015-09-17 16:43:10 -0500 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2015-09-17 16:43:10 -0500 |
commit | 640e6672c36985234929fc94a1b8288a82427699 (patch) | |
tree | 94f67bfa64d04e05b55bb115e9cfd23d5e4c7b34 /include/inn/buffer.h | |
parent | a87c27c80800fdd1d5313eb37b4c304615144cfb (diff) | |
download | smartcardauth-640e6672c36985234929fc94a1b8288a82427699.tar.gz smartcardauth-640e6672c36985234929fc94a1b8288a82427699.zip |
v2.0 Release
Use TDE builtins for almost all functions
This package now only provides the initramfs LUKS configuration and related program(s)
Diffstat (limited to 'include/inn/buffer.h')
-rw-r--r-- | include/inn/buffer.h | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/include/inn/buffer.h b/include/inn/buffer.h deleted file mode 100644 index e9deb2b..0000000 --- a/include/inn/buffer.h +++ /dev/null @@ -1,48 +0,0 @@ -/* $Id: buffer.h 6295 2003-04-16 05:46:38Z rra $ -** -** Counted, reusable memory buffer. -** -** A buffer is an allocated bit of memory with a known size and a separate -** data length. It's intended to store strings and can be reused repeatedly -** to minimize the number of memory allocations. Buffers increase in -** increments of 1K. -** -** A buffer contains a notion of the data that's been used and the data -** that's been left, used when the buffer is an I/O buffer where lots of data -** is buffered and then slowly processed out of the buffer. The total length -** of the data is used + left. If a buffer is just used to store some data, -** used can be set to 0 and left stores the length of the data. -*/ - -#ifndef INN_BUFFER_H -#define INN_BUFFER_H 1 - -#include <inn/defines.h> - -struct buffer { - size_t size; /* Total allocated length. */ - size_t used; /* Data already used. */ - size_t left; /* Remaining unused data. */ - char *data; /* Pointer to allocated memory. */ -}; - -BEGIN_DECLS - -/* Allocate a new buffer and initialize its contents. */ -struct buffer *buffer_new(void); - -/* Resize a buffer to be at least as large as the provided size. */ -void buffer_resize(struct buffer *, size_t); - -/* Set the buffer contents, ignoring anything currently there. */ -void buffer_set(struct buffer *, const char *data, size_t length); - -/* Append data to the buffer. */ -void buffer_append(struct buffer *, const char *data, size_t length); - -/* Swap the contents of two buffers. */ -void buffer_swap(struct buffer *, struct buffer *); - -END_DECLS - -#endif /* INN_BUFFER_H */ |