FS-6500: try to do the bounds checking properly using element of the enum

This commit is contained in:
Michael Jerris 2014-05-01 14:32:23 -04:00
parent 906467b360
commit d2c2f174e7
1 changed files with 2 additions and 2 deletions

View File

@ -543,11 +543,11 @@ static ftdm_status_t ftdm_set_caller_data(ftdm_span_t *span, ftdm_caller_data_t
caller_data->rdnis.type = span->default_caller_data.rdnis.type;
}
if (caller_data->bearer_capability >= FTDM_INVALID_INT_PARM) {
if (caller_data->bearer_capability >= FTDM_BEARER_CAP_INVALID) {
caller_data->bearer_capability = span->default_caller_data.bearer_capability;
}
if (caller_data->bearer_layer1 >= FTDM_INVALID_INT_PARM) {
if (caller_data->bearer_layer1 >= FTDM_USER_LAYER1_PROT_INVALID) {
caller_data->bearer_layer1 = span->default_caller_data.bearer_layer1;
}