[asterisk-scf-commits] asterisk-scf/integration/media_rtp_pjmedia.git branch "ipv6" updated.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Sun May 8 15:27:50 CDT 2011


branch "ipv6" has been updated
       via  c9c0b0122f21bdea2abde40347be16b43f117da5 (commit)
      from  70881290a7b89316f8fb51b6d74f2860082f0341 (commit)

Summary of changes:
 test/TestRTPpjmedia.cpp |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)


- Log -----------------------------------------------------------------
commit c9c0b0122f21bdea2abde40347be16b43f117da5
Author: Joshua Colp <jcolp at digium.com>
Date:   Sun May 8 17:28:36 2011 -0300

    Tweak VerifyLocalAddressonSources test to ensure the local address is of the correct address family.

diff --git a/test/TestRTPpjmedia.cpp b/test/TestRTPpjmedia.cpp
index 9d5ce18..b2b1bef 100644
--- a/test/TestRTPpjmedia.cpp
+++ b/test/TestRTPpjmedia.cpp
@@ -536,8 +536,15 @@ BOOST_AUTO_TEST_CASE(VerifyLocalAddressonSources)
         for (StreamSourceSeq::const_iterator i = sources.begin(); i != sources.end(); ++i)
         {
             StreamSourceRTPPrx source = StreamSourceRTPPrx::checkedCast((*i));
+	    std::string address = source->getLocalAddress();
 
-            if (source->getLocalAddress().empty() || !source->getLocalPort())
+#ifdef IPV6_TEST
+	    std::string valid_char = ":";
+#else
+	    std::string valid_char = ".";
+#endif
+
+            if (address.empty() || !source->getLocalPort() || address.find(valid_char) == string::npos)
             {
                 validaddresses = false;
             }

-----------------------------------------------------------------------


-- 
asterisk-scf/integration/media_rtp_pjmedia.git



More information about the asterisk-scf-commits mailing list