Changeset 3085

Show
Ignore:
Timestamp:
01/29/00 16:28:11 (14 years ago)
Author:
ucacoxh
Message:

- Fix channel.c to write null string in response to

channel_get_parameters if channel coder does not have a
get_parameters function. This fixes gibberish problem when
saving vanilla parameters.

- Logic of strcmp for vanilla was inverted. Doesn't matter as

code got axed.

Location:
rat/trunk
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • rat/trunk/channel.c

    r3078 r3085  
    298298        if (table[cs->coder].enc_get_parameters) { 
    299299                return table[cs->coder].enc_get_parameters(cs->state, cmd, cmd_len); 
     300        } else { 
     301                assert(cmd_len != 0); 
     302                cmd[0] = 0; 
    300303        } 
    301304        return TRUE; 
  • rat/trunk/settings.c

    r3078 r3085  
    675675        if (pri_cf->default_pt != CODEC_PAYLOAD_DYNAMIC) { 
    676676                setting_save_str("audioPrimary",           pri_cf->short_name); 
    677                 /* If vanilla channel coder don't save audioChannelParameters - it's rubbish */ 
    678                 if (strcmp(ccd->name, "Vanilla") == 0) { 
    679                         setting_save_str("audioChannelParameters", cc_param); 
    680                 } else { 
    681                         setting_save_str("audioChannelParameters", "None"); 
    682                 } 
    683677        } 
    684678 
     
    690684        } else { 
    691685                setting_save_str("audioChannelCoding", ccd->name); 
    692         } 
     686 
     687        } 
     688        setting_save_str("audioChannelParameters", cc_param); 
     689 
    693690        setting_save_str("audioRepair",            repair->name); 
    694691        setting_save_str("audioAutoConvert",       converter->name);