Changeset 6402 for trunk/licq
- Timestamp:
- 07/03/08 05:54:19 (5 months ago)
- Location:
- trunk/licq
- Files:
-
- 10 modified
-
include/licq_icqd.h (modified) (7 diffs)
-
include/licq_packets.h (modified) (1 diff)
-
src/icqd-chat.cpp (modified) (4 diffs)
-
src/icqd-filetransfer.cpp (modified) (10 diffs)
-
src/icqd-srv.cpp (modified) (9 diffs)
-
src/icqd-tcp.cpp (modified) (70 diffs)
-
src/icqd-threads.cpp (modified) (5 diffs)
-
src/icqd.cpp (modified) (5 diffs)
-
src/icqpacket.cpp (modified) (6 diffs)
-
src/oscarservice.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/licq/include/licq_icqd.h
r6390 r6402 243 243 unsigned short nLevel, bool bMultipleRecipients = false, 244 244 CICQColor *pColor = NULL); 245 246 unsigned long ProtoSendContactList(const char *szId, unsigned long nPPID,247 UinList &uins, bool bOnline, unsigned short nLevel,248 bool bMultipleRecipients = false, CICQColor *pColor = NULL);249 245 250 246 unsigned long ProtoFetchAutoResponseServer(const char *szId, unsigned long nPPID); … … 551 547 void CancelEvent(unsigned long ); 552 548 void CancelEvent(ICQEvent *); 553 bool OpenConnectionToUser( unsigned long nUin, TCPSocket *sock,549 bool OpenConnectionToUser(const char* id, TCPSocket *sock, 554 550 unsigned short nPort); 555 551 bool OpenConnectionToUser(const char *szAlias, unsigned long nIp, … … 677 673 unsigned long nMsgID2, unsigned short nSequence, 678 674 TCPSocket *pSock); 679 bool WaitForReverseConnection(unsigned short id, unsigned long uin);675 bool WaitForReverseConnection(unsigned short id, const char* userId); 680 676 681 677 protected: … … 841 837 void ProcessFifo(char *); 842 838 843 static bool Handshake_Send(TCPSocket *, unsigned long, unsigned short,839 static bool Handshake_Send(TCPSocket *, const char* id, unsigned short, 844 840 unsigned short, bool = true, unsigned long = 0); 845 841 static bool Handshake_SendConfirm_v7(TCPSocket *); … … 848 844 int ConnectToServer(const char* server, unsigned short port); 849 845 int ConnectToLoginServer(); 850 int ConnectToUser( unsigned long, unsigned char);851 int ReverseConnectToUser( unsigned long nUin, unsigned long nIp,846 int ConnectToUser(const char* id, unsigned char channel); 847 int ReverseConnectToUser(const char* id, unsigned long nIp, 852 848 unsigned short nPort, unsigned short nVersion, unsigned short nFailedPort, 853 849 unsigned long nId, unsigned long nMsgID1, unsigned long nMsgID2); 854 int RequestReverseConnection( unsigned long, unsigned long, unsigned long,850 int RequestReverseConnection(const char* id, unsigned long, unsigned long, 855 851 unsigned short, unsigned short); 856 852 … … 898 894 { 899 895 public: 900 CReverseConnectToUserData( unsigned long uin, unsigned long id,896 CReverseConnectToUserData(const char* idString, unsigned long id, 901 897 unsigned long data, unsigned long ip, unsigned short port, 902 898 unsigned short version, unsigned short failedport, unsigned long msgid1, … … 904 900 ~CReverseConnectToUserData(); 905 901 906 unsigned long nUin;902 std::string myIdString; 907 903 unsigned long nId; 908 904 unsigned long nData; -
trunk/licq/include/licq_packets.h
r6347 r6402 727 727 { 728 728 public: 729 CPU_ReverseConnectFailed( unsigned long nUin, unsigned long nMsgID1,729 CPU_ReverseConnectFailed(const char* id, unsigned long nMsgID1, 730 730 unsigned long nMsgID2, unsigned short nFailedPort, 731 731 unsigned short nOurPort, unsigned long nConnectID); -
trunk/licq/src/icqd-chat.cpp
r6401 r6402 816 816 817 817 // try reverse connect 818 int nId = licqDaemon->RequestReverseConnection(c->m_ nUin, c->m_nSession,818 int nId = licqDaemon->RequestReverseConnection(c->m_szId, c->m_nSession, 819 819 nIp, LocalPort(), c->m_nPort); 820 820 if (nId != -1) … … 854 854 855 855 // Send handshake packet: 856 if (!CICQDaemon::Handshake_Send(&u->sock, c->m_ nUin, LocalPort(),856 if (!CICQDaemon::Handshake_Send(&u->sock, c->m_szId, LocalPort(), 857 857 VersionToUse(c->m_nVersion), false)) 858 858 return false; … … 985 985 iter != licqDaemon->m_lReverseConnect.end(); ++iter) 986 986 { 987 if ((*iter)-> nUin == u->uin)987 if ((*iter)->myIdString == u->Id()) 988 988 { 989 989 bFound = true; … … 2464 2464 pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, NULL); 2465 2465 gLog.Info("%sChat: Waiting for reverse connection.\n", L_TCPxSTR); 2466 bool bConnected = d->WaitForReverseConnection(rc->nId, rc->u-> Uin());2466 bool bConnected = d->WaitForReverseConnection(rc->nId, rc->u->Id()); 2467 2467 pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL); 2468 2468 -
trunk/licq/src/icqd-filetransfer.cpp
r6371 r6402 17 17 #include <sys/types.h> 18 18 #include <fcntl.h> 19 #include <string> 19 20 #include <string.h> 20 21 #include <sys/time.h> … … 43 44 const unsigned short FT_STATE_CONFIRMINGxFILE = 8; 44 45 46 using std::string; 45 47 46 48 … … 352 354 { 353 355 gLog.Info("%sFile Transfer: Connecting to server.\n", L_TCPxSTR); 354 bSuccess = licqDaemon->OpenConnectionToUser(m _nUin, &ftSock, nPort);356 bSuccess = licqDaemon->OpenConnectionToUser(myId, &ftSock, nPort); 355 357 } 356 358 … … 363 365 364 366 // try reverse connect 365 int nId = licqDaemon->RequestReverseConnection(m _nUin, 0, nIp, LocalPort(),367 int nId = licqDaemon->RequestReverseConnection(myId, 0, nIp, LocalPort(), 366 368 nPort); 367 369 … … 393 395 unsigned short nVersion = u->ConnectionVersion(); 394 396 gUserManager.DropUser(u); 395 if (!CICQDaemon::Handshake_Send(&ftSock, m _nUin, LocalPort(), nVersion, false))397 if (!CICQDaemon::Handshake_Send(&ftSock, myId, LocalPort(), nVersion, false)) 396 398 return false; 397 399 … … 481 483 iter != licqDaemon->m_lReverseConnect.end(); ++iter) 482 484 { 483 if ((*iter)->nId == nId && (*iter)-> nUin == m_nUin)485 if ((*iter)->nId == nId && (*iter)->myIdString == myId) 484 486 { 485 487 bFound = true; … … 1255 1257 1256 1258 CICQDaemon *d; 1257 unsigned long nUin;1258 1259 unsigned short nPort; 1259 1260 struct SFileReverseConnectInfo *rc = (struct SFileReverseConnectInfo *)arg; … … 1265 1266 pthread_cleanup_pop(0); 1266 1267 d = rc->m->licqDaemon; 1267 nUin = rc->m->Uin();1268 string id = rc->m->Id(); 1268 1269 nPort = rc->m->m_nPort; 1269 1270 pthread_mutex_unlock(cancel_mutex); … … 1271 1272 pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, NULL); 1272 1273 gLog.Info("%sFile Transfer: Waiting for reverse connection.\n", L_TCPxSTR); 1273 bool bConnected = d->WaitForReverseConnection(rc->nId, nUin);1274 bool bConnected = d->WaitForReverseConnection(rc->nId, id.c_str()); 1274 1275 pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL); 1275 1276 … … 1297 1298 L_TCPxSTR); 1298 1299 TCPSocket s; 1299 bConnected = d->OpenConnectionToUser( nUin, &s, nPort);1300 bConnected = d->OpenConnectionToUser(id.c_str(), &s, nPort); 1300 1301 pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, NULL); 1301 1302 -
trunk/licq/src/icqd-srv.cpp
r6394 r6402 2083 2083 int CICQDaemon::ConnectToServer(const char* server, unsigned short port) 2084 2084 { 2085 SrvSocket *s = new SrvSocket(gUserManager.icqOwnerUin());2085 SrvSocket* s = new SrvSocket(gUserManager.OwnerId(LICQ_PPID).c_str(), LICQ_PPID); 2086 2086 2087 2087 if (m_bProxyEnabled) … … 2179 2179 ParseDigits(szParsedNumber2, szCellular, 15); 2180 2180 if (!strcmp(szParsedNumber1, szParsedNumber2)) 2181 nUin = pUser->Uin();2181 nUin = strtoul(pUser->IdString(), NULL, 10); 2182 2182 } 2183 2183 FOR_EACH_USER_END … … 3115 3115 if ((*iter)->nId == nSubSequence) 3116 3116 { 3117 ICQUser *u = gUserManager.FetchUser((*iter)->nUin, LOCK_R);3117 ICQUser* u = gUserManager.FetchUser((*iter)->myIdString.c_str(), LICQ_PPID, LOCK_R); 3118 3118 if (u == NULL) 3119 gLog.Warn("%sReverse connection from % lufailed.\n", L_WARNxSTR,3120 (*iter)->nUin);3119 gLog.Warn("%sReverse connection from %s failed.\n", L_WARNxSTR, 3120 (*iter)->myIdString.c_str()); 3121 3121 else 3122 3122 { … … 3298 3298 nPort = nPort2; 3299 3299 3300 char id[16]; 3301 snprintf(id, 15, "%lu", nUin); 3302 3300 3303 pthread_t t; 3301 3304 CReverseConnectToUserData *data = new CReverseConnectToUserData( 3302 nUin, nId, ICQ_CHNxUNKNOWN, nIp, nPort,3305 id, nId, ICQ_CHNxUNKNOWN, nIp, nPort, 3303 3306 nVersion, nFailedPort, nMsgID[0], nMsgID[1]); 3304 3307 pthread_create(&t, NULL, &ReverseConnectToUser_tep, data); … … 3908 3911 nFormat = packet.UnpackUnsignedShortBE(); 3909 3912 nUin = packet.UnpackUinString(); 3910 3911 u = gUserManager.FetchUser(nUin, LOCK_W); 3913 char id[16]; 3914 snprintf(id, 15, "%lu", nUin); 3915 3916 u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 3912 3917 if (u == NULL) 3913 3918 { … … 3923 3928 ++iter) 3924 3929 { 3925 if ((*iter)->nId == nMsgID && (*iter)->nUin == nUin)3926 {3930 if ((*iter)->nId == nMsgID && (*iter)->myIdString == id) 3931 { 3927 3932 gLog.Warn("%sReverse connection from %s failed.\n", L_WARNxSTR, 3928 3933 u->GetAlias()); … … 6579 6584 } 6580 6585 6581 int CICQDaemon::RequestReverseConnection( unsigned long nUin,6586 int CICQDaemon::RequestReverseConnection(const char* id, 6582 6587 unsigned long nData, 6583 6588 unsigned long nLocalIP, … … 6585 6590 unsigned short nRemotePort) 6586 6591 { 6587 if ( nUin == gUserManager.icqOwnerUin())6592 if (gUserManager.FindOwner(id, LICQ_PPID) != NULL) 6588 6593 return -1; 6589 6594 6590 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_W);6595 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 6591 6596 if (u == NULL) return -1; 6592 6597 … … 6598 6603 pthread_mutex_lock(&mutex_reverseconnect); 6599 6604 6600 m_lReverseConnect.push_back( 6601 new CReverseConnectToUserData(nUin, nId, nData, nLocalIP, 6602 nLocalPort, ICQ_VERSION_TCP, 6603 nRemotePort, 0, nId)); 6605 m_lReverseConnect.push_back(new CReverseConnectToUserData(id, nId, nData, 6606 nLocalIP, nLocalPort, ICQ_VERSION_TCP, nRemotePort, 0, nId)); 6604 6607 pthread_mutex_unlock(&mutex_reverseconnect); 6605 6608 -
trunk/licq/src/icqd-tcp.cpp
r6382 r6402 1213 1213 * Shake hands on the given socket with the given user. 1214 1214 *-------------------------------------------------------------------------*/ 1215 bool CICQDaemon::Handshake_Send(TCPSocket *s, unsigned long nUin,1215 bool CICQDaemon::Handshake_Send(TCPSocket *s, const char* id, 1216 1216 unsigned short nPort, unsigned short nVersion, bool bConfirm, 1217 1217 unsigned long nId) 1218 1218 { 1219 1219 s->SetVersion(nVersion); 1220 s->SetOwner(nUin); 1220 s->SetOwner(id, LICQ_PPID); 1221 1222 unsigned long nUin = strtoul(id, NULL, 10); 1221 1223 1222 1224 switch (nVersion) … … 1359 1361 * to the global socket manager and to the user. 1360 1362 *----------------------------------------------------------------------------*/ 1361 int CICQDaemon::ConnectToUser( unsigned long nUin, unsigned char nChannel)1362 { 1363 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_W);1363 int CICQDaemon::ConnectToUser(const char* id, unsigned char nChannel) 1364 { 1365 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1364 1366 if (u == NULL) return -1; 1365 1367 … … 1370 1372 { 1371 1373 gUserManager.DropUser(u); 1372 gLog.Warn(tr("%sConnection attempted to already connected user (% ld).\n"),1373 L_WARNxSTR, nUin);1374 gLog.Warn(tr("%sConnection attempted to already connected user (%s).\n"), 1375 L_WARNxSTR, id); 1374 1376 return sd; 1375 1377 } … … 1387 1389 struct timeval tv = { 2, 0 }; 1388 1390 if (select(0, NULL, NULL, NULL, &tv) == -1 && errno == EINTR) return -1; 1389 u = gUserManager.FetchUser( nUin, LOCK_W);1391 u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1390 1392 if (u == NULL) return -1; 1391 1393 } … … 1395 1397 if (sd != -1) return sd; 1396 1398 1397 TCPSocket *s = new TCPSocket(nUin);1398 if (!OpenConnectionToUser( nUin, s, nPort))1399 { 1400 u = gUserManager.FetchUser( nUin, LOCK_W);1399 TCPSocket* s = new TCPSocket(id, LICQ_PPID); 1400 if (!OpenConnectionToUser(id, s, nPort)) 1401 { 1402 u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1401 1403 if (u != NULL) u->SetConnectionInProgress(false); 1402 1404 gUserManager.DropUser(u); … … 1405 1407 } 1406 1408 s->SetChannel(nChannel); 1407 1408 gLog.Info(tr("%sShaking hands with %s (% ld) [v%d].\n"), L_TCPxSTR,1409 szAlias, nUin, nVersion);1409 1410 gLog.Info(tr("%sShaking hands with %s (%s) [v%d].\n"), L_TCPxSTR, 1411 szAlias, id, nVersion); 1410 1412 nPort = s->LocalPort(); 1411 1413 1412 if (!Handshake_Send(s, nUin, 0, nVersion))1413 { 1414 u = gUserManager.FetchUser( nUin, LOCK_W);1414 if (!Handshake_Send(s, id, 0, nVersion)) 1415 { 1416 u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1415 1417 if (u != NULL) u->SetConnectionInProgress(false); 1416 1418 gUserManager.DropUser(u); … … 1422 1424 1423 1425 // Set the socket descriptor in the user 1424 u = gUserManager.FetchUser( nUin, LOCK_W);1426 u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1425 1427 if (u == NULL) return -1; 1426 1428 u->SetSocketDesc(s); … … 1445 1447 * Connects a socket to a given user on a given port. 1446 1448 *----------------------------------------------------------------------------*/ 1447 bool CICQDaemon::OpenConnectionToUser( unsigned long nUin, TCPSocket *sock,1449 bool CICQDaemon::OpenConnectionToUser(const char* id, TCPSocket *sock, 1448 1450 unsigned short nPort) 1449 1451 { 1450 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_R);1452 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_R); 1451 1453 if (u == NULL) return false; 1452 1454 … … 1532 1534 * to the global socket manager and to the user. 1533 1535 *----------------------------------------------------------------------------*/ 1534 int CICQDaemon::ReverseConnectToUser( unsigned long nUin, unsigned long nIp,1536 int CICQDaemon::ReverseConnectToUser(const char* id, unsigned long nIp, 1535 1537 unsigned short nPort, unsigned short nVersion, unsigned short nFailedPort, 1536 1538 unsigned long nId, unsigned long nMsgID1, unsigned long nMsgID2) … … 1551 1553 } 1552 1554 1553 TCPSocket *s = new TCPSocket(nUin);1555 TCPSocket* s = new TCPSocket(id, LICQ_PPID); 1554 1556 char buf[32]; 1555 1557 1556 gLog.Info(tr("%sReverse connecting to % lu at %s:%d.\n"), L_TCPxSTR, nUin,1558 gLog.Info(tr("%sReverse connecting to %s at %s:%d.\n"), L_TCPxSTR, id, 1557 1559 ip_ntoa(nIp, buf), nPort); 1558 1560 … … 1563 1565 { 1564 1566 char buf[128]; 1565 gLog.Warn(tr("%sReverse connect to %lu failed:\n%s%s.\n"), L_WARNxSTR, 1566 nUin, L_BLANKxSTR, s->ErrorStr(buf, 128)); 1567 1568 CPU_ReverseConnectFailed *p = new CPU_ReverseConnectFailed(nUin, nMsgID1, 1569 nMsgID2, nPort, 1570 nFailedPort, nId); 1567 gLog.Warn(tr("%sReverse connect to %s failed:\n%s%s.\n"), L_WARNxSTR, 1568 id, L_BLANKxSTR, s->ErrorStr(buf, 128)); 1569 1570 CPU_ReverseConnectFailed* p = new CPU_ReverseConnectFailed(id, nMsgID1, 1571 nMsgID2, nPort, nFailedPort, nId); 1571 1572 SendEvent_Server(p); 1572 1573 return -1; 1573 1574 } 1574 1575 1575 gLog.Info(tr("%sReverse shaking hands with % lu.\n"), L_TCPxSTR, nUin);1576 gLog.Info(tr("%sReverse shaking hands with %s.\n"), L_TCPxSTR, id); 1576 1577 bool bConfirm = ftm == NULL && cm == NULL; 1577 1578 … … 1579 1580 nVersion = VersionToUse(nVersion); 1580 1581 1581 if (!Handshake_Send(s, nUin, 0, nVersion, bConfirm, nId))1582 if (!Handshake_Send(s, id, 0, nVersion, bConfirm, nId)) 1582 1583 { 1583 1584 delete s; … … 1605 1606 { 1606 1607 // Set the socket descriptor in the user if this user is on our list 1607 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_W);1608 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1608 1609 if (u != NULL) 1609 1610 { … … 1625 1626 bool CICQDaemon::ProcessTcpPacket(TCPSocket *pSock) 1626 1627 { 1627 unsigned long nUin,senderIp, localIp,1628 unsigned long senderIp, localIp, 1628 1629 senderPort, junkLong, nPort, nPortReversed; 1629 1630 unsigned short version, command, junkShort, newCommand, messageLen, … … 1632 1633 bool errorOccured = false; 1633 1634 char *message = 0; 1635 char id[16] = ""; 1634 1636 1635 1637 // only used for v7,v8 … … 1647 1649 case 3: 1648 1650 { 1651 unsigned long nUin; 1649 1652 packet >> nUin 1650 1653 >> version … … 1655 1658 >> messageLen // length of incoming message 1656 1659 ; 1660 snprintf(id, 15, "%lu", nUin); 1657 1661 break; 1658 1662 } … … 1667 1671 return false; 1668 1672 } 1673 unsigned long nUin; 1669 1674 packet >> nUin 1670 1675 >> version … … 1676 1681 >> messageLen // length of incoming message 1677 1682 ; 1683 snprintf(id, 15, "%lu", nUin); 1678 1684 break; 1679 1685 } 1680 1686 case 6: 1681 1687 { 1682 nUin = pSock->Owner();1688 strncpy(id, pSock->OwnerId(), 15); id[15] = '\0'; 1683 1689 if (!Decrypt_Client(&packet, 6)) 1684 1690 { … … 1703 1709 case 8: 1704 1710 { 1705 nUin = pSock->Owner();1711 strncpy(id, pSock->OwnerId(), 15); id[15] = '\0'; 1706 1712 if (!Decrypt_Client(&packet, nInVersion)) 1707 1713 { … … 1725 1731 msgFlags = packet.UnpackUnsignedShort(); 1726 1732 packet >> messageLen; 1727 1733 1728 1734 // Stupid AOL 1729 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_R);1735 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_R); 1730 1736 if (u && (u->LicqVersion() == 0 || u->LicqVersion() >= 1022)) 1731 1737 { … … 1751 1757 1752 1758 // Some simple validation of the packet 1753 if ( nUin == 0|| command == 0)1759 if (id[0] == '\0' || command == 0) 1754 1760 { 1755 1761 char *buf; 1756 gLog.Unknown("%sInvalid TCP packet (uin: % 08lx, cmd: %04x):\n%s\n",1757 L_UNKNOWNxSTR, nUin, command, packet.print(buf));1762 gLog.Unknown("%sInvalid TCP packet (uin: %s, cmd: %04x):\n%s\n", 1763 L_UNKNOWNxSTR, id, command, packet.print(buf)); 1758 1764 delete [] buf; 1759 1765 return false; 1760 1766 } 1761 1767 1762 if ( nUin == gUserManager.icqOwnerUin() || nUin != pSock->Owner())1768 if (gUserManager.FindOwner(id, LICQ_PPID) != NULL || strcmp(id, pSock->OwnerId()) != 0) 1763 1769 { 1764 1770 char *buf; 1765 if ( nUin == gUserManager.icqOwnerUin())1771 if (gUserManager.FindOwner(id, LICQ_PPID) != NULL) 1766 1772 gLog.Warn(tr("%sTCP message from self (probable spoof):\n%s\n"), L_WARNxSTR, packet.print(buf)); 1767 1773 else 1768 gLog.Warn(tr("%sTCP message from invalid UIN (% ld, expect %ld):\n%s\n"),1769 L_WARNxSTR, nUin, pSock->Owner(), packet.print(buf));1774 gLog.Warn(tr("%sTCP message from invalid UIN (%s, expect %s):\n%s\n"), 1775 L_WARNxSTR, id, pSock->OwnerId(), packet.print(buf)); 1770 1776 delete [] buf; 1771 1777 return false; … … 1779 1785 // find which user was sent 1780 1786 bool bNewUser = false; 1781 ICQUser *u = gUserManager.FetchUser(nUin, LOCK_W);1787 ICQUser* u = gUserManager.FetchUser(id, LICQ_PPID, LOCK_W); 1782 1788 if (u == NULL) 1783 1789 { 1784 u = new ICQUser( nUin);1790 u = new ICQUser(id, LICQ_PPID); 1785 1791 u->SetSocketDesc(pSock); 1786 1792 bNewUser = true; … … 1923 1929 nMask |= licqVersion; 1924 1930 if (licqChar == 'L') 1925 gLog.Info(tr("%sMessage from %s (%ld) [Licq %s].\n"), L_TCPxSTR, u->GetAlias(),1926 nUin, CUserEvent::LicqVersionToString(licqVersion));1927 else1928 gLog.Info(tr("%sMessage from %s (%ld).\n"), L_TCPxSTR, u->GetAlias(), nUin);1931 gLog.Info(tr("%sMessage from %s (%s) [Licq %s].\n"), L_TCPxSTR, 1932 u->GetAlias(), id, CUserEvent::LicqVersionToString(licqVersion)); 1933 else 1934 gLog.Info(tr("%sMessage from %s (%s).\n"), L_TCPxSTR, u->GetAlias(), id); 1929 1935 1930 1936 CPT_AckGeneral p(newCommand, theSequence, true, bAccept, u); … … 1951 1957 // FIXME should either refuse the event or have a special auto response 1952 1958 // for rejected events instead of pretending to accept the user 1953 RejectEvent(nUin, e);1959 RejectEvent(id, e); 1954 1960 break; 1955 1961 } … … 1982 1988 packet >> licqChar >> licqVersion; 1983 1989 if (licqChar == 'L') 1984 gLog.Info(tr("%s%s (%ld) requested auto response [Licq %s].\n"), L_TCPxSTR,1985 u->GetAlias(), nUin, CUserEvent::LicqVersionToString(licqVersion));1986 else1987 gLog.Info(tr("%s%s (%ld) requested auto response.\n"), L_TCPxSTR, u->GetAlias(), nUin);1990 gLog.Info(tr("%s%s (%s) requested auto response [Licq %s].\n"), L_TCPxSTR, 1991 u->GetAlias(), id, CUserEvent::LicqVersionToString(licqVersion)); 1992 else 1993 gLog.Info(tr("%s%s (%s) requested auto response.\n"), L_TCPxSTR, u->GetAlias(), id);
