[asterisk-scf-commits] asterisk-scf/examples.git branch "master" updated.

Commits to the Asterisk SCF project code repositories asterisk-scf-commits at lists.digium.com
Wed Aug 3 15:18:15 CDT 2011


branch "master" has been updated
       via  3d8ac5eed7e3c2546939212cc90c0e2584270bda (commit)
      from  466b8d4f2d72ad8926253303e1379a92a587c6b3 (commit)

Summary of changes:
 ExampleSipAuthHook.py |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)


- Log -----------------------------------------------------------------
commit 3d8ac5eed7e3c2546939212cc90c0e2584270bda
Author: Joshua Colp <jcolp at digium.com>
Date:   Wed Aug 3 17:18:39 2011 -0300

    Provide a sane default for the service locator proxy.

diff --git a/ExampleSipAuthHook.py b/ExampleSipAuthHook.py
index 31e979d..2154f52 100755
--- a/ExampleSipAuthHook.py
+++ b/ExampleSipAuthHook.py
@@ -63,6 +63,7 @@ class ExampleAuthHookApp(Ice.Application):
 
         serviceLocator = None
         extensionPoint = None
+        serviceLocatorString = "LocatorService:tcp -p 4411"
 
         for o, a in opts:
             if o in ("-h", "--help"):
@@ -70,7 +71,9 @@ class ExampleAuthHookApp(Ice.Application):
                 return 1
 
             elif o in ("-l", "--locator"):
-                serviceLocator = ServiceLocatorPrx.checkedCast(self.communicator().stringToProxy(a))
+                serviceLocatorString = a
+
+        serviceLocator = ServiceLocatorPrx.checkedCast(self.communicator().stringToProxy(serviceLocatorString))
 
         if serviceLocator == None:
             print >> sys.stderr, "No service locator proxy specified. For usage details please run " + sys.argv[0] + " --help"

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


-- 
asterisk-scf/examples.git



More information about the asterisk-scf-commits mailing list