private string CreateEntry(string text,string prefix)
{
string retVal = "";
if(text.EndsWith("\r\n")){
text = text.Substring(0,text.Length - 2);
}
string remIP = "xxx.xxx.xxx.xxx";
try{
if(m_pSocket.RemoteEndPoint != null){
remIP = ((IPEndPoint)m_pSocket.RemoteEndPoint).Address.ToString();
}
}
catch{
}
string[] lines = text.Replace("\r\n","\n").Split('\n');
foreach(string line in lines){
retVal += "SessionID: " + m_SessionID + " RemIP: " + remIP + " " + prefix + " '" + line + "'\r\n";
}
return retVal;
}