< Previous by Date Date Index Next by Date >
  Thread Index Next in Thread >

[reSIProcate] Does this is Data class bug ?


I want this program outpurt "www.test.com:8080"
But it's output www.test.com:
 

#include <Windows.h>
#include <Rutil/Data.hxx>

using namespace std;
using namespace resip;
#pragma comment(lib, "ws2_32.lib")
#pragma comment(lib, "../lib/Rutil.lib")
 
int main()
{
 string server = "www.test.com";
 int port = 8080;
 Data host = server.c_str();
 host += ":";
 host += port;
 string temp = host.c_str();
 cout << temp << endl;

 return 0;
}