Convert this file over the new method of getting the Asterisk version.

(I don't have this building on this machine, so caio1982 on IRC is going to
 test it for me.  :) )


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@96743 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.6.0
Russell Bryant 18 years ago
parent 54bc2c20b6
commit 4f0cb30f4a

@ -731,10 +731,13 @@ static u_char *ast_var_Version(struct variable *vp, oid *name, size_t *length,
switch (vp->magic) {
case ASTVERSTRING:
*var_len = strlen(ASTERISK_VERSION);
return (u_char *)ASTERISK_VERSION;
{
const char *version = ast_get_version();
*var_len = strlen(version);
return (u_char *)version;
}
case ASTVERTAG:
long_ret = ASTERISK_VERSION_NUM;
sscanf(ast_get_version_num(), "%lu", &long_ret);
return (u_char *)&long_ret;
default:
break;

Loading…
Cancel
Save