SOURCES: libjingle-issue-16.patch (NEW) - patches from libjingle i...

arekm arekm at pld-linux.org
Sun Feb 17 20:41:32 CET 2008


Author: arekm                        Date: Sun Feb 17 19:41:32 2008 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- patches from libjingle issues db

---- Files affected:
SOURCES:
   libjingle-issue-16.patch (NONE -> 1.1)  (NEW)

---- Diffs:

================================================================
Index: SOURCES/libjingle-issue-16.patch
diff -u /dev/null SOURCES/libjingle-issue-16.patch:1.1
--- /dev/null	Sun Feb 17 20:41:32 2008
+++ SOURCES/libjingle-issue-16.patch	Sun Feb 17 20:41:27 2008
@@ -0,0 +1,232 @@
+--- libjingle-orig/talk/base/httpbase.cc	2007-02-02 00:07:25.000000000 -0500
++++ libjingle-64bit/talk/base/httpbase.cc	2007-11-14 13:17:43.143886000 -0500
+@@ -151,10 +151,12 @@
+       } while ((value < eol) && isspace(static_cast<unsigned char>(*value)));
+       size_t vlen = eol - value;
+       if (MatchHeader(line, nlen, HH_CONTENT_LENGTH)) {
+-        if (sscanf(value, "%d", &data_size_) != 1) {
++        unsigned int data_size_temp;
++        if (sscanf(value, "%d", &data_size_temp) != 1) {
+           err = HE_PROTOCOL;
+           break;
+         }
++        data_size_ = data_size_temp;
+       } else if (MatchHeader(line, nlen, HH_TRANSFER_ENCODING)) {
+         if ((vlen == 7) && (_strnicmp(value, "chunked", 7) == 0)) {
+           chunked_ = true;
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/session/phone/linphonemediaengine.cc libjingle-new-ortp/talk/session/phone/linphonemediaengine.cc
+--- libjingle-orig/talk/session/phone/linphonemediaengine.cc	2007-02-02 00:07:30.000000000 -0500
++++ libjingle-new-ortp/talk/session/phone/linphonemediaengine.cc	2007-07-19 11:24:09.000000000 -0400
+@@ -80,19 +80,19 @@
+     } 
+ #endif
+ #ifdef HAVE_SPEEX
+-    if (i->name == speex_wb.mime_type && i->clockrate == speex_wb.clock_rate) {
+-      rtp_profile_set_payload(&av_profile, i->id, &speex_wb);
+-    } else if (i->name == speex_nb.mime_type && i->clockrate == speex_nb.clock_rate) {
+-      rtp_profile_set_payload(&av_profile, i->id, &speex_nb);
++    if (i->name == payload_type_speex_wb.mime_type && i->clockrate == payload_type_speex_wb.clock_rate) {
++      rtp_profile_set_payload(&av_profile, i->id, &payload_type_speex_wb);
++    } else if (i->name == payload_type_speex_nb.mime_type && i->clockrate == payload_type_speex_nb.clock_rate) {
++      rtp_profile_set_payload(&av_profile, i->id, &payload_type_speex_nb);
+     }
+ #endif
+ 
+     if (i->id == 0)
+-      rtp_profile_set_payload(&av_profile, 0, &pcmu8000);
++      rtp_profile_set_payload(&av_profile, 0, &payload_type_pcmu8000);
+ 
+-    if (i->name == telephone_event.mime_type) {
++/*    if (i->name == telephone_event.mime_type) {
+       rtp_profile_set_payload(&av_profile, i->id, &telephone_event);
+-    }
++    }*/
+     
+     if (first) {
+       LOG(LS_INFO) << "Using " << i->name << "/" << i->clockrate;
+@@ -114,12 +114,12 @@
+ bool LinphoneMediaEngine::FindCodec(const Codec &c) {
+   if (c.id == 0)
+     return true;
+-  if (c.name == telephone_event.mime_type)
+-    return true;
++/*  if (c.name == telephone_event.mime_type)
++    return true;*/
+ #ifdef HAVE_SPEEX
+-  if (c.name == speex_wb.mime_type && c.clockrate == speex_wb.clock_rate)
++  if (c.name == payload_type_speex_wb.mime_type && c.clockrate == payload_type_speex_wb.clock_rate)
+     return true;
+-  if (c.name == speex_nb.mime_type && c.clockrate == speex_nb.clock_rate)
++  if (c.name == payload_type_speex_nb.mime_type && c.clockrate == payload_type_speex_nb.clock_rate)
+     return true;
+ #endif
+ #ifdef HAVE_ILBC
+@@ -171,8 +171,8 @@
+ #ifdef HAVE_SPEEX
+   ms_speex_codec_init();
+ 
+-  codecs_.push_back(Codec(110, speex_wb.mime_type, speex_wb.clock_rate, 0, 1, 8));
+-  codecs_.push_back(Codec(111, speex_nb.mime_type, speex_nb.clock_rate, 0, 1, 7));
++  codecs_.push_back(Codec(110, payload_type_speex_wb.mime_type, payload_type_speex_wb.clock_rate, 0, 1, 8));
++  codecs_.push_back(Codec(111, payload_type_speex_nb.mime_type, payload_type_speex_nb.clock_rate, 0, 1, 7));
+   
+ #endif
+ 
+@@ -181,8 +181,8 @@
+   codecs_.push_back(Codec(102, payload_type_ilbc.mime_type, payload_type_ilbc.clock_rate, 0, 1, 4));
+ #endif
+ 
+-  codecs_.push_back(Codec(0, pcmu8000.mime_type, pcmu8000.clock_rate, 0, 1, 2));
+-  codecs_.push_back(Codec(101, telephone_event.mime_type, telephone_event.clock_rate, 0, 1, 1));
++  codecs_.push_back(Codec(0, payload_type_pcmu8000.mime_type, payload_type_pcmu8000.clock_rate, 0, 1, 2));
++ // codecs_.push_back(Codec(101, telephone_event.mime_type, telephone_event.clock_rate, 0, 1, 1));
+   return true;
+ }
+ 
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/third_party/mediastreamer/audiostream.c libjingle-new-ortp/talk/third_party/mediastreamer/audiostream.c
+--- libjingle-orig/talk/third_party/mediastreamer/audiostream.c	2007-02-02 00:07:32.000000000 -0500
++++ libjingle-new-ortp/talk/third_party/mediastreamer/audiostream.c	2007-07-19 11:55:32.000000000 -0400
+@@ -112,7 +112,7 @@
+ 			RtpSession **recvsend){
+ 	RtpSession *rtpr;
+ 	rtpr=rtp_session_new(RTP_SESSION_SENDRECV);
+-	rtp_session_max_buf_size_set(rtpr,MAX_RTP_SIZE);
++	rtp_session_set_recv_buf_size(rtpr,MAX_RTP_SIZE);
+ 	rtp_session_set_profile(rtpr,profile);
+ 	rtp_session_set_local_addr(rtpr,get_local_addr_for(remip),locport);
+ 	if (remport>0) rtp_session_set_remote_addr(rtpr,remip,remport);
+@@ -133,7 +133,7 @@
+ 	/* creates two rtp filters to recv send streams (remote part)*/
+ 	
+ 	rtps=rtp_session_new(RTP_SESSION_SENDONLY);
+-	rtp_session_max_buf_size_set(rtps,MAX_RTP_SIZE);
++	rtp_session_set_recv_buf_size(rtps,MAX_RTP_SIZE);
+ 	rtp_session_set_profile(rtps,profile);
+ #ifdef INET6
+ 	rtp_session_set_local_addr(rtps,"::",locport+2);
+@@ -147,7 +147,7 @@
+ 	rtp_session_set_jitter_compensation(rtps,jitt_comp);
+ 	
+ 	rtpr=rtp_session_new(RTP_SESSION_RECVONLY);
+-	rtp_session_max_buf_size_set(rtpr,MAX_RTP_SIZE);
++	rtp_session_set_recv_buf_size(rtpr,MAX_RTP_SIZE);
+ 	rtp_session_set_profile(rtpr,profile);
+ #ifdef INET6
+ 	rtp_session_set_local_addr(rtpr,"::",locport);
+@@ -217,8 +217,8 @@
+ 	ms_filter_set_property(stream->decoder,MS_FILTER_PROPERTY_FREQ,&pt->clock_rate);
+ 	ms_filter_set_property(stream->decoder,MS_FILTER_PROPERTY_BITRATE,&pt->normal_bitrate);
+ 	
+-	ms_filter_set_property(stream->encoder,MS_FILTER_PROPERTY_FMTP, (void*)pt->fmtp);
+-	ms_filter_set_property(stream->decoder,MS_FILTER_PROPERTY_FMTP,(void*)pt->fmtp);
++	ms_filter_set_property(stream->encoder,MS_FILTER_PROPERTY_FMTP, (void*)pt->send_fmtp);
++	ms_filter_set_property(stream->decoder,MS_FILTER_PROPERTY_FMTP,(void*)pt->recv_fmtp);
+ 	/* create the synchronisation source */
+ 	stream->timer=ms_timer_new();
+ 	
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/third_party/mediastreamer/msrtprecv.c libjingle-new-ortp/talk/third_party/mediastreamer/msrtprecv.c
+--- libjingle-orig/talk/third_party/mediastreamer/msrtprecv.c	2007-02-02 00:07:32.000000000 -0500
++++ libjingle-new-ortp/talk/third_party/mediastreamer/msrtprecv.c	2007-07-19 11:40:11.000000000 -0400
+@@ -26,7 +26,7 @@
+ MSMessage *msgb_2_ms_message(mblk_t* mp){
+ 	MSMessage *msg;
+ 	MSBuffer *msbuf;
+-	if (mp->b_datap->ref_count!=1) return NULL; /* cannot handle properly non-unique buffers*/
++	if (mp->b_datap->db_ref!=1) return NULL; /* cannot handle properly non-unique buffers*/
+ 	/* create a MSBuffer using the mblk_t buffer */
+ 	msg=ms_message_alloc();
+ 	msbuf=ms_buffer_alloc(0);
+@@ -120,7 +120,7 @@
+ 		gint got=0;
+ 		/* we are connected with queues (surely for video)*/
+ 		/* use the sync system time to compute a timestamp */
+-		PayloadType *pt=rtp_profile_get_payload(r->rtpsession->profile,r->rtpsession->payload_type);
++		PayloadType *pt=rtp_profile_get_payload(rtp_session_get_recv_profile(r->rtpsession),rtp_session_get_recv_payload_type(r->rtpsession));
+ 		if (pt==NULL) {
+ 			ms_warning("ms_rtp_recv_process(): NULL RtpPayload- skipping.");
+ 			return;
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/third_party/mediastreamer/msrtpsend.c libjingle-new-ortp/talk/third_party/mediastreamer/msrtpsend.c
+--- libjingle-orig/talk/third_party/mediastreamer/msrtpsend.c	2007-02-02 00:07:32.000000000 -0500
++++ libjingle-new-ortp/talk/third_party/mediastreamer/msrtpsend.c	2007-07-19 11:41:26.000000000 -0400
+@@ -85,7 +85,7 @@
+ {
+ 	guint32 clockts;
+ 	/* use the sync system time to compute a timestamp */
+-	PayloadType *pt=rtp_profile_get_payload(r->rtpsession->profile,r->rtpsession->payload_type);
++	PayloadType *pt=rtp_profile_get_payload(rtp_session_get_send_profile(r->rtpsession),rtp_session_get_send_payload_type(r->rtpsession));
+ 	g_return_val_if_fail(pt!=NULL,0);
+ 	clockts=(guint32)(((double)synctime * (double)pt->clock_rate)/1000.0);
+ 	ms_trace("ms_rtp_send_process: sync->time=%i clock=%i",synctime,clockts);
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/base/base64.h libjingle-gcc4/talk/base/base64.h
+--- libjingle-orig/talk/base/base64.h	2007-02-02 00:07:22.000000000 -0500
++++ libjingle-gcc4/talk/base/base64.h	2007-07-19 10:44:53.000000000 -0400
+@@ -23,8 +23,8 @@
+   static std::string decode(const std::string & data);
+   static std::string encodeFromArray(const char * data, size_t len);
+ private:
+-  static const std::string Base64::Base64Table;
+-  static const std::string::size_type Base64::DecodeTable[];
++  static const std::string Base64Table;
++  static const std::string::size_type DecodeTable[];
+ };
+ 
+ } // namespace talk_base
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/base/stringutils.h libjingle-gcc4/talk/base/stringutils.h
+--- libjingle-orig/talk/base/stringutils.h	2007-02-02 00:07:22.000000000 -0500
++++ libjingle-gcc4/talk/base/stringutils.h	2007-07-19 10:44:00.000000000 -0400
+@@ -269,7 +269,7 @@
+ template<>
+ struct Traits<char> {
+   typedef std::string string;
+-  inline static const char* Traits<char>::empty_str() { return ""; }
++  inline static const char* empty_str() { return ""; }
+ };
+ 
+ ///////////////////////////////////////////////////////////////////////////////
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/p2p/base/sessionmanager.h libjingle-gcc4/talk/p2p/base/sessionmanager.h
+--- libjingle-orig/talk/p2p/base/sessionmanager.h	2007-02-02 00:07:27.000000000 -0500
++++ libjingle-gcc4/talk/p2p/base/sessionmanager.h	2007-07-19 10:59:37.000000000 -0400
+@@ -156,7 +156,7 @@
+ 
+   // Creates and returns an error message from the given components.  The
+   // caller is responsible for deleting this.
+-  buzz::XmlElement* SessionManager::CreateErrorMessage(
++  buzz::XmlElement* CreateErrorMessage(
+       const buzz::XmlElement* stanza,
+       const buzz::QName& name,
+       const std::string& type,
+diff --exclude='Makefile*' --exclude='.*' --exclude='*~' --exclude='*.lo' --exclude='*.o' -aurbB libjingle-orig/talk/xmpp/xmppclient.h libjingle-gcc4/talk/xmpp/xmppclient.h
+--- libjingle-orig/talk/xmpp/xmppclient.h	2007-02-02 00:07:26.000000000 -0500
++++ libjingle-gcc4/talk/xmpp/xmppclient.h	2007-07-19 10:55:20.000000000 -0400
+@@ -138,7 +138,7 @@
+     }
+   }
+ 
+-  std::string XmppClient::GetStateName(int state) const {
++  std::string GetStateName(int state) const {
+     switch (state) {
+       case STATE_PRE_XMPP_LOGIN:      return "PRE_XMPP_LOGIN";
+       case STATE_START_XMPP_LOGIN:  return "START_XMPP_LOGIN";
+--- libjingle-0.4.0.orig/talk/session/fileshare/fileshare.cc	2007-02-02 08:07:29.000000000 +0300
++++ libjingle-0.4.0/talk/session/fileshare/fileshare.cc	2007-06-22 13:06:35.406203685 +0400
+@@ -670,8 +670,8 @@
+         && !query.empty()
+         && (sscanf(query.c_str(), "width=%u&height=%u",
+                    &width, &height) == 2)) {
+-      width = talk_base::_max<unsigned int>(1, talk_base::_min(width, kMaxPreviewSize));
+-      height = talk_base::_max<unsigned int>(1, talk_base::_min(height, kMaxPreviewSize));
++      width = talk_base::_max<unsigned int>(1, talk_base::_min<unsigned int>(width, kMaxPreviewSize));
++      height = talk_base::_max<unsigned int>(1, talk_base::_min<unsigned int>(height, kMaxPreviewSize));
+       std::string pathname;
+       if (is_sender_) {
+         talk_base::Pathname local_path;
+--- libjingle-orig/talk/base/criticalsection.h	2007-02-02 00:07:23.000000000 -0500
++++ libjingle-mutexfix/talk/base/criticalsection.h	2007-11-14 13:29:57.198232000 -0500
+@@ -83,6 +83,7 @@
+ public:
+   CriticalSection() {
+     pthread_mutexattr_t mutex_attribute;
++    pthread_mutexattr_init(&mutex_attribute);
+     pthread_mutexattr_settype(&mutex_attribute, PTHREAD_MUTEX_RECURSIVE);
+     pthread_mutex_init(&mutex_, &mutex_attribute);
+   }
================================================================


More information about the pld-cvs-commit mailing list