diff options
author | Greg Hudson <ghudson@mit.edu> | 2014-05-04 15:43:35 -0400 |
---|---|---|
committer | Greg Hudson <ghudson@mit.edu> | 2014-05-17 18:45:27 -0400 |
commit | ccd989bdc2656b153bc226462e0c13800810ae04 (patch) | |
tree | 538f35a5cccac48c2afb7e93106cdf3e4bf8af0f /src/include | |
parent | ba1558660f0cbd8639ac323dac11c52f88ac079d (diff) | |
download | krb5-ccd989bdc2656b153bc226462e0c13800810ae04.zip krb5-ccd989bdc2656b153bc226462e0c13800810ae04.tar.gz krb5-ccd989bdc2656b153bc226462e0c13800810ae04.tar.bz2 |
Add k5_buf_get_space
Add a new k5_buf method to make room in the buffer for the caller to
fill in.
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/k5-buf.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/include/k5-buf.h b/src/include/k5-buf.h index c5576a3..da10fd9 100644 --- a/src/include/k5-buf.h +++ b/src/include/k5-buf.h @@ -91,6 +91,10 @@ void k5_buf_add_fmt(struct k5buf *buf, const char *fmt, ...) #endif ; +/* Extend the length of buf by len and return a pointer to the reserved space, + * to be filled in by the caller. Return NULL on error. */ +void *k5_buf_get_space(struct k5buf *buf, size_t len); + /* Truncate BUF. LEN must be between 0 and the existing buffer * length, or an assertion failure will result. */ void k5_buf_truncate(struct k5buf *buf, size_t len); |