]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
mod_oreka: use zstr instead of only checking for null as some caller profile data...
authorMoises Silva <moy@sangoma.com>
Tue, 13 Aug 2013 15:58:56 +0000 (11:58 -0400)
committerMoises Silva <moy@sangoma.com>
Tue, 13 Aug 2013 15:58:56 +0000 (11:58 -0400)
src/mod/applications/mod_oreka/mod_oreka.c

index f954341b4c6e1dd9ba26a25b650ff51291dcdd41..a9c8c927e111bcee8b273d3002e3b7901e711559 100644 (file)
@@ -274,17 +274,17 @@ static int oreka_send_sip_message(oreka_session_t *oreka, oreka_recording_status
        caller_id_number = switch_caller_get_field_by_name(caller_profile, "caller_id_number");
        
        caller_id_name = switch_caller_get_field_by_name(caller_profile, "caller_id_name");
-       if (!caller_id_name) {
+       if (zstr(caller_id_name)) {
                caller_id_name = caller_id_number;
        }
 
        callee_id_number = switch_caller_get_field_by_name(caller_profile, "callee_id_number");
-       if (!callee_id_number) {
+       if (zstr(callee_id_number)) {
                callee_id_number = switch_caller_get_field_by_name(caller_profile, "destination_number");
        }
 
        callee_id_name = switch_caller_get_field_by_name(caller_profile, "callee_id_name");
-       if (!callee_id_name) {
+       if (zstr(callee_id_name)) {
                callee_id_name = callee_id_number;
        }