convert ast_copy_string to use AST_INLINE_API macro (bug #4682)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6108 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Russell Bryant 2005-07-12 15:26:24 +00:00
parent 4f64fe03f0
commit b62623fdaa
1 changed files with 3 additions and 7 deletions

View File

@ -135,12 +135,8 @@ char *ast_strip_quoted(char *s, const char *beg_quotes, const char *end_quotes);
reduced buffer size to this function (unlike \a strncpy), and the buffer does not need
to be initialized to zeroes prior to calling this function.
*/
void ast_copy_string(char *dst, const char *src, size_t size);
#if !defined(LOW_MEMORY) && !defined(AST_API_MODULE)
extern inline
#endif
#if !defined(LOW_MEMORY) || defined(AST_API_MODULE)
void ast_copy_string(char *dst, const char *src, size_t size)
AST_INLINE_API(
void ast_copy_string(char *dst, const char *src, size_t size),
{
while (*src && size) {
*dst++ = *src++;
@ -150,7 +146,7 @@ void ast_copy_string(char *dst, const char *src, size_t size)
dst--;
*dst = '\0';
}
#endif
)
/*!
\brief Build a string in a buffer, designed to be called repeatedly