From: Luigi Rizzo Date: Fri, 15 Dec 2006 14:33:59 +0000 (+0000) Subject: small documentation improvements. X-Git-Tag: 1.6.0-beta1~3^2~3728 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=286f02bf40137703d03d0fbb442b5601f209c52f;p=thirdparty%2Fasterisk.git small documentation improvements. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@48495 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/include/asterisk/threadstorage.h b/include/asterisk/threadstorage.h index b5ad0b2b5c..d087f81d04 100644 --- a/include/asterisk/threadstorage.h +++ b/include/asterisk/threadstorage.h @@ -162,13 +162,15 @@ void *ast_threadstorage_get(struct ast_threadstorage *ts, size_t init_size), void __ast_threadstorage_cleanup(void *); /*! - * \brief A dynamic length string + * A dynamic length string. This is just a C string prefixed by a length + * field. len reflects the actual space allocated, while the string is + * NUL-terminated as a regular C string. + * One should never declare a variable with this type, but only a pointer + * to it, and use ast_dynamic_str_create() to initialize it. */ struct ast_dynamic_str { - /* The current maximum length of the string */ - size_t len; - /* The string buffer */ - char str[0]; + size_t len; /*!< The current maximum length of the string */ + char str[0]; /*!< The string buffer */ }; /*! @@ -179,7 +181,7 @@ struct ast_dynamic_str { * \return This function returns a pointer to the dynamic string length. The * result will be NULL in the case of a memory allocation error. * - * /note The result of this function is dynamically allocated memory, and must + * \note The result of this function is dynamically allocated memory, and must * be free()'d after it is no longer needed. */ AST_INLINE_API(