windows compiler fixes.

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9847 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Michael Jerris 2008-10-05 06:27:45 +00:00
parent 26453e1035
commit 85788d0c4a
2 changed files with 10 additions and 9 deletions

View File

@ -701,17 +701,17 @@ SWITCH_STANDARD_API(ctl_function)
switch_core_session_ctl(SCSC_PAUSE_INBOUND, &arg);
stream->write_function(stream, "+OK\n");
} else if (!strcasecmp(argv[0], "shutdown")) {
switch_session_ctl_t cmd = SCSC_SHUTDOWN;
switch_session_ctl_t command = SCSC_SHUTDOWN;
int x = 0;
arg = 0;
for (x = 1; x < 5; x++) {
if (argv[x]) {
if (!strcasecmp(argv[x], "cancel")) {
arg = 0;
cmd = SCSC_CANCEL_SHUTDOWN;
command = SCSC_CANCEL_SHUTDOWN;
break;
} else if (!strcasecmp(argv[x], "elegant")) {
cmd = SCSC_SHUTDOWN_ELEGANT;
command = SCSC_SHUTDOWN_ELEGANT;
} else if (!strcasecmp(argv[x], "restart")) {
arg = 1;
}
@ -719,7 +719,7 @@ SWITCH_STANDARD_API(ctl_function)
break;
}
}
switch_core_session_ctl(cmd, &arg);
switch_core_session_ctl(command, &arg);
stream->write_function(stream, "+OK\n");
} else if (!strcasecmp(argv[0], "reclaim_mem")) {
switch_core_session_ctl(SCSC_RECLAIM, &arg);
@ -2596,6 +2596,7 @@ SWITCH_STANDARD_API(hupall_api_function)
if (!switch_strlen_zero(cmd) && (mycmd = strdup(cmd))) {
argc = switch_separate_string(mycmd, ' ', argv, (sizeof(argv) / sizeof(argv[0])));
switch_assert(argv[0]);
if ((cause = switch_channel_str2cause(argv[0])) == SWITCH_CAUSE_NONE) {
cause = SWITCH_CAUSE_MANAGER_REQUEST;
}

View File

@ -588,7 +588,7 @@ SWITCH_STANDARD_API(start_local_stream_function)
if (argv[5]) {
tmp = atoi(argv[5]);
if (tmp == 1 || tmp == 2) {
channels = tmp;
channels = (uint8_t)tmp;
}
}
@ -622,24 +622,24 @@ SWITCH_STANDARD_API(start_local_stream_function)
char *val = (char *) switch_xml_attr_soft(param, "value");
if (!strcasecmp(var, "rate")) {
int tmp = atoi(val);
tmp = atoi(val);
if (tmp == 8000 || tmp == 16000 || tmp == 32000) {
rate = tmp;
}
} else if (!strcasecmp(var, "shuffle")) {
shuffle = switch_true(val);
} else if (!strcasecmp(var, "prebuf")) {
int tmp = atoi(val);
tmp = atoi(val);
if (tmp > 0) {
prebuf = (uint32_t) tmp;
}
} else if (!strcasecmp(var, "channels")) {
int tmp = atoi(val);
tmp = atoi(val);
if (tmp == 1 || tmp == 2) {
channels = (uint8_t) tmp;
}
} else if (!strcasecmp(var, "interval")) {
int tmp = atoi(val);
tmp = atoi(val);
if (SWITCH_ACCEPTABLE_INTERVAL(tmp)) {
interval = tmp;
} else {