[OpenSIPStack] Problem with PIPSocket::Address
Brought to you by:
joegenbaclor
From: Claudio M. <cmi...@gm...> - 2008-01-15 12:54:09
|
Hi, I have a problem using some objects from pwlib. In the following example, when I use the method Byte2 in the PIPSocket::Address endereco_local, I do not receive a result (empty space). I think I am creating the object incorrectly. #define PTRACING 1 #include <ptlib.h> #include <rtp/rtp.h> #include <iostream> using namespace std; class Oi: public PProcess{ PCLASSINFO(Oi, PProcess) public: void Main(); }; PCREATE_PROCESS(Oi) void Oi::Main() { char * filename = "C:\\Documents and Settings\\claudio\\Desktop\\ttt\\src\\krishna.txt" ; cout << "My test"; PTrace::Initialise(32, filename, PTrace::Blocks | PTrace::Timestamp | PTrace::Thread |PTrace::FileAndLine); PTRACE(1,"Inside test. Buda helps me \n"); PString not_buda = PString("127.0.0.1"); PIPSocket::Address endereco_local = PIPSocket::Address(not_buda); //endereco_local PTRACE(1,"endereco_local " << endereco_local << "\n"); PTRACE(1,"not_buda " << not_buda); PTRACE(1,"Byte2 " << endereco_local.Byte2()); } Thanks in advance Claudio Miceli de Farias |