mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-19 19:52:48 +00:00
Merge changes from str_substitution that are unrelated to that branch.
Included is a small bugfix to an ast_str helper, but most of these changes are simply doxygen fixes. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@185912 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -66,7 +66,7 @@ int __ast_str_helper(struct ast_str **buf, size_t max_len,
|
||||
}
|
||||
/*
|
||||
* Ask vsnprintf how much space we need. Remember that vsnprintf
|
||||
* does not count the final '\0' so we must add 1.
|
||||
* does not count the final <code>'\0'</code> so we must add 1.
|
||||
*/
|
||||
va_copy(aq, ap);
|
||||
res = vsnprintf((*buf)->__AST_STR_STR + offset, (*buf)->__AST_STR_LEN - offset, fmt, aq);
|
||||
@@ -156,11 +156,10 @@ char *__ast_str_helper2(struct ast_str **buf, size_t maxlen, const char *src, si
|
||||
ptr += (*buf)->__AST_STR_STR - oldbase;
|
||||
}
|
||||
}
|
||||
if (__builtin_expect(!(maxsrc && maxlen), 0)) {
|
||||
if (__builtin_expect(!maxlen, 0)) {
|
||||
ptr--;
|
||||
}
|
||||
*ptr = '\0';
|
||||
(*buf)->__AST_STR_USED--;
|
||||
return (*buf)->__AST_STR_STR;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user