Ignore:
Timestamp:
Mar 6, 2006 1:30:39 PM (18 years ago)
Author:
bennylp
Message:

Fixed bug if payload type for rx and tx is different (i.e. dyn pt)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • pjproject/trunk/pjmedia/src/pjmedia/stream.c

    r229 r290  
    132132 
    133133    pj_strerror(status, errmsg, sizeof(errmsg)); 
    134     PJ_LOG(3,(sender, "%s: %s [err:%d]", title, errmsg, status)); 
     134    PJ_LOG(4,(sender, "%s: %s [err:%d]", title, errmsg, status)); 
    135135} 
    136136 
     
    510510            status != PJMEDIA_RTP_ESESSRESTART)  
    511511        { 
    512             TRACE_((THIS_FILE, "RTP session_update error", status)); 
     512            TRACE_((THIS_FILE, "RTP session_update error (details follows)",  
     513                    status)); 
     514            PJ_LOG(4,(THIS_FILE,"RTP packet detail: pt=%d, seq=%d", 
     515                      hdr->pt, pj_ntohs(hdr->seq))); 
    513516            continue; 
    514517        } 
     
    558561                                   pjmedia_stream *stream, 
    559562                                   pjmedia_dir dir, 
     563                                   unsigned pt, 
    560564                                   const pjmedia_stream_info *param, 
    561565                                   const pjmedia_codec_param *codec_param, 
     
    575579    channel->dir = dir; 
    576580    channel->paused = 1; 
    577     channel->pt = param->fmt.pt; 
     581    channel->pt = pt; 
    578582 
    579583    /* Allocate buffer for incoming packet. */ 
     
    609613    /* Create RTP and RTCP sessions: */ 
    610614 
    611     status = pjmedia_rtp_session_init(&channel->rtp, param->fmt.pt,  
    612                                  param->ssrc); 
     615    status = pjmedia_rtp_session_init(&channel->rtp, pt, param->ssrc); 
    613616    if (status != PJ_SUCCESS) 
    614617        return status; 
     
    749752    /* Create decoder channel: */ 
    750753 
    751     status = create_channel( pool, stream, PJMEDIA_DIR_DECODING, info, 
    752                              &codec_param, &stream->dec); 
     754    status = create_channel( pool, stream, PJMEDIA_DIR_DECODING,  
     755                             info->fmt.pt, info, &codec_param, &stream->dec); 
    753756    if (status != PJ_SUCCESS) 
    754757        goto err_cleanup; 
     
    757760    /* Create encoder channel: */ 
    758761 
    759     status = create_channel( pool, stream, PJMEDIA_DIR_ENCODING, info, 
    760                              &codec_param, &stream->enc); 
     762    status = create_channel( pool, stream, PJMEDIA_DIR_ENCODING,  
     763                             info->tx_pt, info, &codec_param, &stream->enc); 
    761764    if (status != PJ_SUCCESS) 
    762765        goto err_cleanup; 
Note: See TracChangeset for help on using the changeset viewer.