add 'consumed' argument to ast_get_time_t, so callers can know how many characters were used in the parser

update pbx_dundi to use ast_get_time_t
eliminate some compiler warnings


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@10871 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Kevin P. Fleming
2006-02-23 17:13:57 +00:00
parent c3447c7cce
commit 302c943001
11 changed files with 22 additions and 19 deletions

View File

@@ -228,9 +228,10 @@ void ast_join(char *s, size_t len, char * const w[]);
\param src String to parse
\param dst Destination
\param _default Value to use if the string does not contain a valid time
\param consumed The number of characters 'consumed' in the string by the parse (see 'man sscanf' for details)
\return zero on success, non-zero on failure
*/
int ast_get_time_t(const char *src, time_t *dst, time_t _default);
int ast_get_time_t(const char *src, time_t *dst, time_t _default, int *consumed);
/* The realloca lets us ast_restrdupa(), but you can't mix any other ast_strdup calls! */