<h1>Project "FreeSWITCH user-contributed scripts, etc" received a push.</h1>

<h2>branch: master updated</h2>
<pre>
       via: d89c16dbe9b0293be09fc6f0d3d1905fd2470fd3 (commit)
      from: 510a78e4ab5f20a15f09a69e39d4417da7a1dcf3 (commit)


</pre>= COMMIT LOG ===========================================================
<div class="highlight"><pre>committer: Mitch Capper
comments: 
broker.cs: set event handlers to null to avoid pesky warning.  Added no empty params check to EventSocket as it actually fixes a not yet patched issue in FS and add warning about tls port also if sofia cannot load and tls is enabled.

<span style="color: #000080; font-weight: bold">diff --git a/mitchcapper/FSClient/Broker.cs b/mitchcapper/FSClient/Broker.cs</span>
<span style="color: #000080; font-weight: bold">index 959dc0d..7ba9817 100644</span>
<span style="color: #A00000">--- a/mitchcapper/FSClient/Broker.cs</span>
<span style="color: #00A000">+++ b/mitchcapper/FSClient/Broker.cs</span>
<span style="color: #800080; font-weight: bold">@@ -481,7 +481,7 @@ namespace FSClient {</span>
                         }
                 }
                 private bool _ClearDTMFS;
<span style="color: #A00000">-                public Utils.ObjectEventHandler&lt;bool&gt; ClearDTMFSChanged;</span>
<span style="color: #00A000">+                public Utils.ObjectEventHandler&lt;bool&gt; ClearDTMFSChanged = null;</span>
 
                 public bool SpeakerphoneActive {
                         get { return _SpeakerphoneActive; }
<span style="color: #800080; font-weight: bold">@@ -525,7 +525,7 @@ namespace FSClient {</span>
                         get { return _active_calls; }
                 }
                 private int _active_calls;
<span style="color: #A00000">-                public Utils.ObjectEventHandler&lt;int&gt; active_callsChanged;</span>
<span style="color: #00A000">+                public Utils.ObjectEventHandler&lt;int&gt; active_callsChanged = null;</span>
 
 
                 public bool CanEnd //true when hangup would have an effect, an active call or a ringing call, dial tone
<span style="color: #000080; font-weight: bold">diff --git a/mitchcapper/FSClient/EventSocket.cs b/mitchcapper/FSClient/EventSocket.cs</span>
<span style="color: #000080; font-weight: bold">index 76cc03b..3ba3fbb 100644</span>
<span style="color: #A00000">--- a/mitchcapper/FSClient/EventSocket.cs</span>
<span style="color: #00A000">+++ b/mitchcapper/FSClient/EventSocket.cs</span>
<span style="color: #800080; font-weight: bold">@@ -33,12 +33,16 @@ namespace FSClient {</span>
                                                                                 new Field(Field.FIELD_TYPE.Bool,&quot;Nat Map&quot;,&quot;nat-map&quot;,&quot;nat-map&quot;,&quot;false&quot;,&quot;&quot;),
                                                                                 new Field(Field.FIELD_TYPE.Combo,&quot;Debug Mode&quot;,&quot;debug&quot;,&quot;debug&quot;,&quot;0&quot;,&quot;&quot;,new Field.FieldOption{display_value=&quot;true&quot;, value=&quot;1&quot;},new Field.FieldOption{display_value=&quot;false&quot;, value=&quot;0&quot;}),
         };
<span style="color: #00A000">+                private static string[] AllowedEmptyFields = new[] { &quot;password&quot;, &quot;listen-ip&quot; };</span>
                 public FieldValue[] values = FieldValue.FieldValues(fields);
                 public void gen_config(XmlNode config_node){
                         XmlNode settings = XmlUtils.AddNodeNode(config_node, &quot;settings&quot;);
                         foreach (FieldValue value in values) {
<span style="color: #A00000">-                                if (!String.IsNullOrEmpty(value.field.xml_name))</span>
<span style="color: #A00000">-                                        Utils.add_xml_param(settings, value.field.xml_name, value.value);</span>
<span style="color: #00A000">+                                if (String.IsNullOrEmpty(value.field.xml_name))</span>
<span style="color: #00A000">+                                        continue;</span>
<span style="color: #00A000">+                                if (String.IsNullOrWhiteSpace(value.value) &amp;&amp; !AllowedEmptyFields.Contains(value.field.name))</span>
<span style="color: #00A000">+                                        continue;</span>
<span style="color: #00A000">+                                Utils.add_xml_param(settings, value.field.xml_name, value.value);</span>
                         }
                 }
                 public void reload_config(){
<span style="color: #000080; font-weight: bold">diff --git a/mitchcapper/FSClient/Sofia.cs b/mitchcapper/FSClient/Sofia.cs</span>
<span style="color: #000080; font-weight: bold">index 83dbbb5..40c1ad7 100644</span>
<span style="color: #A00000">--- a/mitchcapper/FSClient/Sofia.cs</span>
<span style="color: #00A000">+++ b/mitchcapper/FSClient/Sofia.cs</span>
<span style="color: #800080; font-weight: bold">@@ -138,8 +138,11 @@ namespace FSClient {</span>
                 public void sofia_profile_check() {
                         master_profile_ok = true;
                         String res = Utils.api_exec(&quot;sofia&quot;, &quot;status profile softphone&quot;);
<span style="color: #A00000">-                        if (res.Trim() == &quot;Invalid Profile!&quot;) {</span>
<span style="color: #A00000">-                                MessageBox.Show(&quot;Warning the master sofia profile was not able to load and the phone will most likely _not_ work, make sure the local bind port (&quot; + FieldValue.GetByName(values, &quot;sip-port&quot;).value + &quot;) is free(set under the Advanced tab of in the sofia settings) and FSClient is allowed through your firewall, otherwise check the freeswitch.log for more details.  You can try reloading the sofia profile by editing the sofia settings and clicking save to see if fixed.&quot;);</span>
<span style="color: #00A000">+                        if (res.Trim() == &quot;Invalid Profile!&quot;){</span>
<span style="color: #00A000">+                                String tls_port_msg = &quot;&quot;;</span>
<span style="color: #00A000">+                                if (FieldValue.GetByName(values, &quot;tls&quot;).value == &quot;true&quot;)</span>
<span style="color: #00A000">+                                        tls_port_msg += &quot; and tls bind port (&quot; + FieldValue.GetByName(values, &quot;tls-sip-port&quot;).value + &quot;)&quot;;</span>
<span style="color: #00A000">+                                MessageBox.Show(&quot;Warning the master sofia profile was not able to load and the phone will most likely _not_ work, make sure the local bind port (&quot; + FieldValue.GetByName(values, &quot;sip-port&quot;).value + &quot;)&quot; + tls_port_msg + &quot; is free(set under the Advanced tab of in the sofia settings) and FSClient is allowed through your firewall, otherwise check the freeswitch.log for more details.  You can try reloading the sofia profile by editing the sofia settings and clicking save to see if fixed.&quot;);</span>
                                 master_profile_ok = false;
                         }
 
</pre></div>
========================================================================<pre>

Summary of changes:
 mitchcapper/FSClient/Broker.cs      |    4 ++--
 mitchcapper/FSClient/EventSocket.cs |    8 ++++++--
 mitchcapper/FSClient/Sofia.cs       |    7 +++++--
 3 files changed, 13 insertions(+), 6 deletions(-)
</pre>
<p>this email was generated because of /git/your-repo.git/hooks/post-receive by the file /git-core/contrib/hooks/post-receive-email<br />
For more info, see <a href="http://blog.chomperstomp.com/?p=630">http://blog.chomperstomp.com/?p=630</a>
-- <br />
FreeSWITCH user-contributed scripts, etc</p>