make build on windows.
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@3912 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
parent
7fac72df6c
commit
63bf54fee1
|
@ -291,6 +291,8 @@ static switch_status_t strepoch_api_function(char *data, switch_core_session_t *
|
|||
}
|
||||
|
||||
stream->write_function(stream, "%d", (uint32_t)apr_time_sec(out));
|
||||
|
||||
return SWITCH_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
static switch_status_t strftime_api_function(char *fmt, switch_core_session_t *session, switch_stream_handle_t *stream)
|
||||
|
|
|
@ -402,13 +402,10 @@ static switch_status_t en_say_money(switch_core_session_t *session,
|
|||
{
|
||||
switch_channel_t *channel;
|
||||
|
||||
int x = 0;
|
||||
char sbuf[16] = ""; // enuf for 999,999,999,999.99 (w/o the commas)
|
||||
|
||||
double amt, dollars, cents;
|
||||
|
||||
switch_status_t status;
|
||||
|
||||
assert(session != NULL);
|
||||
channel = switch_core_session_get_channel(session);
|
||||
assert(channel != NULL);
|
||||
|
@ -419,9 +416,7 @@ static switch_status_t en_say_money(switch_core_session_t *session,
|
|||
}
|
||||
|
||||
amt = atof(tosay); //convert to double
|
||||
dollars = trunc(amt); // get whole dollars
|
||||
cents = trunc(fabs((amt - dollars))*100.0); // get cents as whole integer (dropping sign)
|
||||
dollars = fabs(dollars); // lose the sign
|
||||
cents = modf(fabs(amt), &dollars); // split dollars and cents
|
||||
|
||||
// If negative say "negative" (or "minus")
|
||||
if (amt < 0.0) {
|
||||
|
|
|
@ -2389,7 +2389,7 @@ SWITCH_DECLARE(switch_status_t) switch_ivr_originate(switch_core_session_t *sess
|
|||
for (hi = switch_channel_variable_first(caller_channel, switch_core_session_get_pool(session)); hi; hi = switch_hash_next(hi)) {
|
||||
switch_hash_this(hi, &vvar, NULL, &vval);
|
||||
if (vvar && vval) {
|
||||
switch_event_add_header(var_event, SWITCH_STACK_BOTTOM, vvar, vval);
|
||||
switch_event_add_header(var_event, SWITCH_STACK_BOTTOM, (void *)vvar, vval);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue