problem with receiving of incoming requests

Discussion related to implementation and use of the H.323 Plus H.323 stack at http://www.h323plus.org.
Post Reply
beginner
Posts: 1
Joined: Wed Sep 25, 2013 6:51 pm

problem with receiving of incoming requests

Post by beginner »

Hi, all! I'm beginner in h323plus. Today I encountered a problem with receiving incoming requests (RAS). I use simple.exe client from samples and Wireshark in testing. Simple.exe with key -l send gatekeeperRequest. I can see it in Wireshark, but application doesn't call OnDiscovery callback of H323GatekeeperServer instance. This code shows my attempts to run listener:

Code: Select all

#include <ptlib.h>
#include <ptlib/pprocess.h>
#include <h323.h>
#include "gkserver.h" //from samples folder

class SimpleServer : public PProcess
{
public:
    SimpleServer();
    virtual void Main();
};

PCREATE_PROCESS(SimpleServer)

SimpleServer::SimpleServer() : PProcess("beginner", "SimpleServer", 1, 1, 1, 1)
{
}

void SimpleServer::Main()
{
    PString Addr = "127.0.0.1";
    WORD Port = 1718;

    H323EndPoint *EP = new H323EndPoint;
    H323Gatekeeperserver * GKServer = new H323Gatekeeperserver(*EP);
    H323TransportUDP *TP = new H323TransportUDP(*EP, Addr, Port);
    GKServer->CreateListener(TP);
}
Besides, I don't have any troubles with sending of RAS requests and handle responses (on OnGatekeeperConfirm, OnGatekeeperConfirm and other callbacks).

Code: Select all

//////////
    PString Addr = "127.0.0.1";
    WORD Port = 1718;

    H323EndPoint *EP = new H323EndPoint;
    H323ListenerTCP *Listener = new H323ListenerTCP(*EP, Addr, Port);
    EP->StartListener(Listener);
    EP->UseGatekeeper();
/////////
Please, help me with receiving RAS requests.
I look forward to the answer.

Post Reply