[asterisk-commits] oej: branch group/pinana-publish-1.4 r286383 - in /team/group/pinana-publish-...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Sep 13 10:14:32 CDT 2010
Author: oej
Date: Mon Sep 13 10:14:26 2010
New Revision: 286383
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=286383
Log:
Adding XML2 support (from svn trunk)
Modified:
team/group/pinana-publish-1.4/channels/chan_sip.c
team/group/pinana-publish-1.4/configure
team/group/pinana-publish-1.4/configure.ac
team/group/pinana-publish-1.4/include/asterisk/autoconfig.h.in
Modified: team/group/pinana-publish-1.4/channels/chan_sip.c
URL: http://svnview.digium.com/svn/asterisk/team/group/pinana-publish-1.4/channels/chan_sip.c?view=diff&rev=286383&r1=286382&r2=286383
==============================================================================
--- team/group/pinana-publish-1.4/channels/chan_sip.c (original)
+++ team/group/pinana-publish-1.4/channels/chan_sip.c Mon Sep 13 10:14:26 2010
@@ -639,6 +639,15 @@
/*! \brief Global list of addresses dynamic peers are not allowed to use */
static struct ast_ha *global_contact_ha = NULL;
static int global_dynamic_exclude_static = 0;
+
+/*!
+ * We use libxml2 in order to parse XML that may appear in the body of a SIP message. Currently,
+ * the only usage is for parsing dialog-info bodies of incoming NOTIFY messages in the dialog-info
+ * event package. This variable is set at module load time and may be checked at runtime to determine
+ * if XML parsing support was found.
+ */
+static int can_parse_xml;
+
/* Object counters */
static int suserobjs = 0; /*!< Static users */
@@ -1881,6 +1890,16 @@
};
AST_LIST_HEAD_STATIC(epa_static_data_list, epa_backend);
+
+static int sip_is_xml_parsable(void)
+{
+#ifdef HAVE_LIBXML2
+ return TRUE;
+#else
+ return FALSE;
+#endif
+}
+
static int sip_epa_register(const struct epa_static_data *static_data)
{
@@ -19506,6 +19525,8 @@
}
}
+ /* Check if we have the xml parsers we need */
+ can_parse_xml = sip_is_xml_parsable();
/* Now load the presence configuration */
pcfg = ast_config_load("sip-presence.conf");
if (pcfg) {
Modified: team/group/pinana-publish-1.4/configure.ac
URL: http://svnview.digium.com/svn/asterisk/team/group/pinana-publish-1.4/configure.ac?view=diff&rev=286383&r1=286382&r2=286383
==============================================================================
--- team/group/pinana-publish-1.4/configure.ac (original)
+++ team/group/pinana-publish-1.4/configure.ac Mon Sep 13 10:14:26 2010
@@ -242,6 +242,7 @@
AST_EXT_LIB_SETUP([KDE], [KDE], [kde])
AST_LIBCURL_CHECK_CONFIG([], [7.10.1])
AST_EXT_LIB_SETUP([LTDL], [libtool], [ltdl])
+AST_EXT_LIB_SETUP([LIBXML2], [LibXML2], [libxml2])
AST_EXT_LIB_SETUP([MISDN], [mISDN User Library], [misdn])
AST_EXT_LIB_SETUP([NBS], [Network Broadcast Sound], [nbs])
AST_EXT_LIB_SETUP([NCURSES], [ncurses], [ncurses])
Modified: team/group/pinana-publish-1.4/include/asterisk/autoconfig.h.in
URL: http://svnview.digium.com/svn/asterisk/team/group/pinana-publish-1.4/include/asterisk/autoconfig.h.in?view=diff&rev=286383&r1=286382&r2=286383
==============================================================================
--- team/group/pinana-publish-1.4/include/asterisk/autoconfig.h.in (original)
+++ team/group/pinana-publish-1.4/include/asterisk/autoconfig.h.in Mon Sep 13 10:14:26 2010
@@ -220,6 +220,9 @@
/* Define if your system has the KDE libraries. */
#undef HAVE_LIBKDE
+
+/* Define to 1 if you have the LibXML2 library. */
+#undef HAVE_LIBXML2
/* Define to 1 if you have the <limits.h> header file. */
#undef HAVE_LIMITS_H
More information about the asterisk-commits
mailing list