X-Git-Url: https://git.distorted.org.uk/~mdw/disorder/blobdiff_plain/812b526d127c6657e571db8b33a58137af6709cd..9e42afcd09973d589b58be8f503f05b9f292c3b4:/lib/vector.h diff --git a/lib/vector.h b/lib/vector.h index 31dfeda..fdef9cf 100644 --- a/lib/vector.h +++ b/lib/vector.h @@ -1,6 +1,6 @@ /* * This file is part of DisOrder. - * Copyright (C) 2004, 2005, 2007, 2008 Richard Kettlewell + * Copyright (C) 2004, 2005, 2007-2009, 2013 Richard Kettlewell * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -79,6 +79,8 @@ VECTOR_TYPE(vector, char *, xrealloc); /** @brief A dynamic string */ VECTOR_TYPE(dynstr, char, xrealloc_noptr); /** @brief A dynamic unicode string */ +VECTOR_TYPE(dynstr_utf16, uint16_t, xrealloc_noptr); +/** @brief A dynamic wide character string */ VECTOR_TYPE(dynstr_ucs4, uint32_t, xrealloc_noptr); /** @brief A dynamic array of pointers to unicode string */ VECTOR_TYPE(vector32, uint32_t *, xrealloc); @@ -94,6 +96,9 @@ static inline void dynstr_append_string(struct dynstr *v, const char *ptr) { dynstr_append_bytes(v, ptr, strlen(ptr)); } +void free_strings(int nvec, char **vec); +void vector_clear(struct vector *v); + #endif /* VECTOR_H */ /*