mirror of the now-defunct rocklinux.org
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1158 lines
40 KiB

  1. # --- ROCK-COPYRIGHT-NOTE-BEGIN ---
  2. #
  3. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  4. # Please add additional copyright information _after_ the line containing
  5. # the ROCK-COPYRIGHT-NOTE-END tag. Otherwise it might get removed by
  6. # the ./scripts/Create-CopyPatch script. Do not edit this copyright text!
  7. #
  8. # ROCK Linux: rock-src/package/misc/centericq/gcc34.patch
  9. # ROCK Linux is Copyright (C) 1998 - 2005 Clifford Wolf
  10. #
  11. # This patch file is dual-licensed. It is available under the license the
  12. # patched project is licensed under, as long as it is an OpenSource license
  13. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  14. # of the GNU General Public License as published by the Free Software
  15. # Foundation; either version 2 of the License, or (at your option) any later
  16. # version.
  17. #
  18. # --- ROCK-COPYRIGHT-NOTE-END ---
  19. --- ./libicq2000-0.1/libicq2000/sigslot.h.orig 2004-02-11 01:51:44.000000000 +0200
  20. +++ ./libicq2000-0.1/libicq2000/sigslot.h 2004-05-04 11:35:10.000000000 +0300
  21. @@ -745,8 +745,8 @@
  22. public:
  23. _connection0()
  24. {
  25. - pobject = NULL;
  26. - pmemfun = NULL;
  27. + this->pobject = NULL;
  28. + this->pmemfun = NULL;
  29. }
  30. _connection0(dest_type* pobject, void (dest_type::*pmemfun)())
  31. @@ -786,8 +786,8 @@
  32. public:
  33. _connection1()
  34. {
  35. - pobject = NULL;
  36. - pmemfun = NULL;
  37. + this->pobject = NULL;
  38. + this->pmemfun = NULL;
  39. }
  40. _connection1(dest_type* pobject, void (dest_type::*pmemfun)(arg1_type))
  41. @@ -827,8 +827,8 @@
  42. public:
  43. _connection2()
  44. {
  45. - pobject = NULL;
  46. - pmemfun = NULL;
  47. + this->pobject = NULL;
  48. + this->pmemfun = NULL;
  49. }
  50. _connection2(dest_type* pobject, void (dest_type::*pmemfun)(arg1_type, arg2_type))
  51. @@ -889,7 +889,7 @@
  52. lock_block<mt_policy> lock(this);
  53. _connection0<dest_type, mt_policy>* conn
  54. = new _connection0<dest_type, mt_policy>(pclass, pmemfun);
  55. - m_connected_slots.push_back(conn);
  56. + this->m_connected_slots.push_back(conn);
  57. pclass->signal_connect(this);
  58. }
  59. @@ -897,15 +897,15 @@
  60. {
  61. lock_block<mt_policy> lock(this);
  62. _sig_connection0<mt_policy>* conn = new _sig_connection0<mt_policy>(chainsig);
  63. - m_connected_slots.push_back(conn);
  64. + this->m_connected_slots.push_back(conn);
  65. chainsig.signal_connect(this);
  66. }
  67. void emit()
  68. {
  69. lock_block<mt_policy> lock(this);
  70. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  71. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  72. + typename _signal_base0< mt_policy >::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  73. + typename _signal_base0< mt_policy >::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  74. while(it != itEnd)
  75. {
  76. @@ -921,8 +921,8 @@
  77. void operator()()
  78. {
  79. lock_block<mt_policy> lock(this);
  80. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  81. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  82. + typename _signal_base0< mt_policy >::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  83. + typename _signal_base0< mt_policy >::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  84. while(it != itEnd)
  85. {
  86. @@ -957,7 +957,7 @@
  87. lock_block<mt_policy> lock(this);
  88. _connection1<dest_type, arg1_type, mt_policy>* conn
  89. = new _connection1<dest_type, arg1_type, mt_policy>(pclass, pmemfun);
  90. - m_connected_slots.push_back(conn);
  91. + this->m_connected_slots.push_back(conn);
  92. pclass->signal_connect(this);
  93. }
  94. @@ -965,15 +965,15 @@
  95. {
  96. lock_block<mt_policy> lock(this);
  97. _sig_connection1<arg1_type, mt_policy>* conn = new _sig_connection1<arg1_type, mt_policy>(chainsig);
  98. - m_connected_slots.push_back(conn);
  99. + this->m_connected_slots.push_back(conn);
  100. chainsig.signal_connect(this);
  101. }
  102. void emit(arg1_type a1)
  103. {
  104. lock_block<mt_policy> lock(this);
  105. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  106. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  107. + typename _signal_base1<arg1_type, mt_policy>::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  108. + typename _signal_base1<arg1_type, mt_policy>::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  109. while(it != itEnd)
  110. {
  111. @@ -989,8 +989,8 @@
  112. void operator()(arg1_type a1)
  113. {
  114. lock_block<mt_policy> lock(this);
  115. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  116. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  117. + typename _signal_base1<arg1_type, mt_policy>::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  118. + typename _signal_base1<arg1_type, mt_policy>::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  119. while(it != itEnd)
  120. {
  121. @@ -1025,7 +1025,7 @@
  122. lock_block<mt_policy> lock(this);
  123. _connection2<dest_type, arg1_type, arg2_type, mt_policy>* conn
  124. = new _connection2<dest_type, arg1_type, arg2_type, mt_policy>(pclass, pmemfun);
  125. - m_connected_slots.push_back(conn);
  126. + this->m_connected_slots.push_back(conn);
  127. pclass->signal_connect(this);
  128. }
  129. @@ -1033,15 +1033,15 @@
  130. {
  131. lock_block<mt_policy> lock(this);
  132. _sig_connection2<arg1_type, arg2_type, mt_policy>* conn = new _sig_connection2<arg1_type, arg2_type, mt_policy>(chainsig);
  133. - m_connected_slots.push_back(conn);
  134. + this->m_connected_slots.push_back(conn);
  135. chainsig.signal_connect(this);
  136. }
  137. void emit(arg1_type a1, arg2_type a2)
  138. {
  139. lock_block<mt_policy> lock(this);
  140. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  141. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  142. + typename _signal_base2<arg1_type, arg2_type, mt_policy>::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  143. + typename _signal_base2<arg1_type, arg2_type, mt_policy>::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  144. while(it != itEnd)
  145. {
  146. @@ -1057,8 +1057,8 @@
  147. void operator()(arg1_type a1, arg2_type a2)
  148. {
  149. lock_block<mt_policy> lock(this);
  150. - typename connections_list::const_iterator itNext, it = m_connected_slots.begin();
  151. - typename connections_list::const_iterator itEnd = m_connected_slots.end();
  152. + typename _signal_base2<arg1_type, arg2_type, mt_policy>::connections_list::const_iterator itNext, it = this->m_connected_slots.begin();
  153. + typename _signal_base2<arg1_type, arg2_type, mt_policy>::connections_list::const_iterator itEnd = this->m_connected_slots.end();
  154. while(it != itEnd)
  155. {
  156. --- ./src/accountmanager.cc.orig 2004-02-04 09:44:41.000000000 +0200
  157. +++ ./src/accountmanager.cc 2004-05-04 12:46:43.460755640 +0300
  158. @@ -47,7 +47,7 @@
  159. void accountmanager::exec() {
  160. dialogbox db;
  161. - protocolname pname;
  162. + int pname;
  163. icqconf::imaccount account;
  164. int n, b, i, citem, action, pos;
  165. set<hookcapab::enumeration> capab;
  166. @@ -75,15 +75,15 @@
  167. for(fin = false; !fin; ) {
  168. t.clear();
  169. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  170. - account = conf.getourid(pname);
  171. + for(pname = icq; pname != protocolname_size; pname += 1) {
  172. + account = conf.getourid((protocolname)pname);
  173. if(pname != rss)
  174. - if(gethook(pname).enabled() || !account.empty()) {
  175. - account = conf.getourid(pname);
  176. - n = t.addnode(0, 0, 0, " " + conf.getprotocolname(pname) + " ");
  177. - citem = ((int) (pname)+1) * 100;
  178. - capab = gethook(pname).getCapabs();
  179. + if(gethook((protocolname)pname).enabled() || !account.empty()) {
  180. + account = conf.getourid((protocolname)pname);
  181. + n = t.addnode(0, 0, 0, " " + conf.getprotocolname((protocolname)pname) + " ");
  182. + citem = (pname+1) * 100;
  183. + capab = gethook((protocolname)pname).getCapabs();
  184. if(!account.empty()) {
  185. tmp = "";
  186. @@ -154,9 +154,9 @@
  187. pname = (protocolname) (citem/100-1);
  188. action = citem-(citem/100)*100;
  189. - spname = conf.getprotocolname(pname);
  190. - account = conf.getourid(pname);
  191. - abstracthook &hook = gethook(pname);
  192. + spname = conf.getprotocolname((protocolname)pname);
  193. + account = conf.getourid((protocolname)pname);
  194. + abstracthook &hook = gethook((protocolname)pname);
  195. switch(action) {
  196. case 1:
  197. @@ -190,7 +190,7 @@
  198. case 8:
  199. if(!hook.online()) {
  200. - account = icqconf::imaccount(pname);
  201. + account = icqconf::imaccount((protocolname)pname);
  202. } else {
  203. face.status(_("You have to disconnect the service first!"));
  204. }
  205. @@ -215,9 +215,9 @@
  206. break;
  207. case 10:
  208. - if(face.edit(tmp = conf.getawaymsg(pname),
  209. + if(face.edit(tmp = conf.getawaymsg((protocolname)pname),
  210. spname + ": " + _("away message"))) {
  211. - conf.setawaymsg(pname, tmp);
  212. + conf.setawaymsg((protocolname)pname, tmp);
  213. }
  214. break;
  215. --- ./src/centericq.cc.orig 2004-04-11 19:32:27.000000000 +0300
  216. +++ ./src/centericq.cc 2004-05-04 13:38:34.300836064 +0300
  217. @@ -71,8 +71,8 @@
  218. if(p)
  219. if(rus = (((string) p).substr(0, 2) == "ru")) {
  220. conf.setcharsets("cp1251", "koi8-r");
  221. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  222. - conf.setcpconvert(pname, true);
  223. + for(int pname = icq; pname != protocolname_size; pname += 1)
  224. + conf.setcpconvert((protocolname)pname, true);
  225. }
  226. if(updateconf()) {
  227. @@ -118,20 +118,20 @@
  228. }
  229. bool centericq::checkpasswords() {
  230. - protocolname pname;
  231. + int pname;
  232. icqconf::imaccount ia;
  233. bool r;
  234. r = regmode = true;
  235. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  236. - if(gethook(pname).enabled() && !gethook(pname).getCapabs().count(hookcapab::optionalpassword)) {
  237. - if(!(ia = conf.getourid(pname)).empty()) {
  238. + for(pname = icq; pname != protocolname_size; pname += 1) {
  239. + if(gethook((protocolname)pname).enabled() && !gethook((protocolname)pname).getCapabs().count(hookcapab::optionalpassword)) {
  240. + if(!(ia = conf.getourid((protocolname)pname)).empty()) {
  241. if(ia.password.empty()) {
  242. conf.setsavepwd(false);
  243. ia.password = face.inputstr("[" +
  244. - conf.getprotocolname(pname) + "] " +
  245. + conf.getprotocolname((protocolname)pname) + "] " +
  246. _("password: "), "", '*');
  247. if(ia.password.empty()) {
  248. @@ -150,10 +150,10 @@
  249. }
  250. void centericq::inithooks() {
  251. - protocolname pname;
  252. + int pname;
  253. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  254. - gethook(pname).init();
  255. + for(pname = icq; pname != protocolname_size; pname += 1) {
  256. + gethook((protocolname)pname).init();
  257. }
  258. }
  259. @@ -836,25 +836,25 @@
  260. }
  261. void centericq::rereadstatus() {
  262. - protocolname pname;
  263. + int pname;
  264. icqconf::imaccount ia;
  265. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  266. - ia = conf.getourid(pname);
  267. + for(pname = icq; pname != protocolname_size; pname += 1) {
  268. + ia = conf.getourid((protocolname)pname);
  269. if(!ia.empty()) {
  270. char cst;
  271. - imstatus st;
  272. - string fname = conf.getconfigfname((string) "status-" + conf.getprotocolname(pname));
  273. + int st;
  274. + string fname = conf.getconfigfname((string) "status-" + conf.getprotocolname((protocolname)pname));
  275. ifstream f(fname.c_str());
  276. if(f.is_open()) {
  277. f >> cst, f.close(), f.clear();
  278. unlink(fname.c_str());
  279. - for(st = offline; st != imstatus_size; (int) st += 1) {
  280. + for(st = offline; st != imstatus_size; st += 1) {
  281. if(imstatus2char[st] == cst) {
  282. - gethook(pname).setstatus(st);
  283. + gethook((protocolname)pname).setstatus((imstatus)st);
  284. break;
  285. }
  286. }
  287. @@ -1360,7 +1360,7 @@
  288. fd_set rfds, wfds, efds;
  289. struct timeval tv;
  290. int hsockfd;
  291. - protocolname pname;
  292. + int pname;
  293. for(keypressed = fin = false; !keypressed && !fin; ) {
  294. timer_keypress = lastkeypress();
  295. @@ -1375,8 +1375,8 @@
  296. if(!regmode) {
  297. exectimers();
  298. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  299. - abstracthook &hook = gethook(pname);
  300. + for(pname = icq; pname != protocolname_size; pname += 1) {
  301. + abstracthook &hook = gethook((protocolname)pname);
  302. if(hook.online()) {
  303. hook.getsockets(rfds, wfds, efds, hsockfd);
  304. @@ -1394,8 +1394,8 @@
  305. keypressed = true;
  306. time(&timer_keypress);
  307. } else {
  308. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  309. - abstracthook &hook = gethook(pname);
  310. + for(pname = icq; pname != protocolname_size; pname += 1) {
  311. + abstracthook &hook = gethook((protocolname)pname);
  312. if(hook.online())
  313. if(hook.isoursocket(rfds, wfds, efds)) {
  314. @@ -1410,7 +1410,7 @@
  315. }
  316. void centericq::setauto(imstatus astatus) {
  317. - protocolname pname;
  318. + int pname;
  319. imstatus stcurrent;
  320. static bool autoset = false;
  321. bool nautoset, changed = false;
  322. @@ -1424,8 +1424,8 @@
  323. nautoset = false;
  324. }
  325. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  326. - abstracthook &hook = gethook(pname);
  327. + for(pname = icq; pname != protocolname_size; pname += 1) {
  328. + abstracthook &hook = gethook((protocolname)pname);
  329. stcurrent = hook.getstatus();
  330. if(hook.logged())
  331. @@ -1437,7 +1437,7 @@
  332. default:
  333. if(autoset && (astatus == available)) {
  334. face.log(_("+ [%s] status restored"),
  335. - conf.getprotocolname(pname).c_str());
  336. + conf.getprotocolname((protocolname)pname).c_str());
  337. hook.restorestatus();
  338. nautoset = false;
  339. @@ -1452,7 +1452,7 @@
  340. nautoset = changed = true;
  341. face.log(_("+ [%s] automatically set %s"),
  342. - conf.getprotocolname(pname).c_str(),
  343. + conf.getprotocolname((protocolname)pname).c_str(),
  344. astatus == away ? _("away") : _("n/a"));
  345. }
  346. }
  347. @@ -1469,7 +1469,7 @@
  348. #define MINCK0(x, y) (x ? (y ? (x > y ? y : x) : x) : y)
  349. void centericq::exectimers() {
  350. - protocolname pname;
  351. + int pname;
  352. int paway, pna;
  353. bool fonline = false;
  354. @@ -1481,9 +1481,9 @@
  355. *
  356. */
  357. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  358. - if(!conf.getourid(pname).empty() || (pname == rss)) {
  359. - abstracthook &hook = gethook(pname);
  360. + for(pname = icq; pname != protocolname_size; pname += 1) {
  361. + if(!conf.getourid((protocolname)pname).empty() || (pname == rss)) {
  362. + abstracthook &hook = gethook((protocolname)pname);
  363. /*
  364. *
  365. @@ -1495,7 +1495,7 @@
  366. static map<protocolname, reconnectInfo> reconnect;
  367. - if(timer_current-reconnect[pname].timer > reconnect[pname].period) {
  368. + if(timer_current-reconnect[(protocolname)pname].timer > reconnect[(protocolname)pname].period) {
  369. /*
  370. *
  371. * Any need to try auto re-connecting?
  372. @@ -1503,15 +1503,15 @@
  373. */
  374. if(!hook.logged()) {
  375. - reconnect[pname].timer = timer_current;
  376. + reconnect[(protocolname)pname].timer = timer_current;
  377. - if(reconnect[pname].period < 180)
  378. - reconnect[pname].period += reconnect[pname].period/2;
  379. + if(reconnect[(protocolname)pname].period < 180)
  380. + reconnect[(protocolname)pname].period += reconnect[(protocolname)pname].period/2;
  381. if(hook.online()) {
  382. hook.disconnect();
  383. - } else if(conf.getstatus(pname) != offline) {
  384. + } else if(conf.getstatus((protocolname)pname) != offline) {
  385. if(conf.enoughdiskspace() && !manager.isopen()) {
  386. hook.connect();
  387. }
  388. @@ -1519,7 +1519,7 @@
  389. }
  390. } else {
  391. fonline = true;
  392. - reconnect[pname] = reconnectInfo();
  393. + reconnect[(protocolname)pname] = reconnectInfo();
  394. }
  395. }
  396. }
  397. @@ -1577,8 +1577,8 @@
  398. if(!conf.enoughdiskspace()) {
  399. if(fonline) {
  400. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  401. - gethook(pname).disconnect();
  402. + for(pname = icq; pname != protocolname_size; pname += 1)
  403. + gethook((protocolname)pname).disconnect();
  404. face.log(_("! free disk space is less than 10k, going offline"));
  405. face.log(_("! otherwise we can lose events and configuration"));
  406. --- ./src/hooks/abstracthook.cc.orig 2004-04-11 19:32:28.000000000 +0300
  407. +++ ./src/hooks/abstracthook.cc 2004-05-04 12:25:17.237291328 +0300
  408. @@ -71,9 +71,9 @@
  409. void abstracthook::setstatus(imstatus st) {
  410. setautostatus(manualstatus = st);
  411. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1) {
  412. - if(&gethook(pname) == this) {
  413. - conf.savestatus(pname, manualstatus);
  414. + for(int pname = icq; pname != protocolname_size; pname += 1) {
  415. + if(&gethook((protocolname)pname) == this) {
  416. + conf.savestatus((protocolname)pname, manualstatus);
  417. break;
  418. }
  419. }
  420. --- ./src/icqconf.cc.orig 2004-03-17 21:08:31.000000000 +0200
  421. +++ ./src/icqconf.cc 2004-05-04 12:58:09.218504616 +0300
  422. @@ -52,7 +52,7 @@
  423. savepwd = mailcheck = fenoughdiskspace = true;
  424. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1) {
  425. + for(int pname = icq; pname != protocolname_size; pname += 1) {
  426. chatmode[pname] = true;
  427. cpconvert[pname] = entersends[pname] = nonimonline[pname] = false;
  428. }
  429. @@ -376,7 +376,7 @@
  430. string fname = getconfigfname("config"), buf, param, rbuf;
  431. ifstream f(fname.c_str());
  432. imaccount im;
  433. - protocolname pname;
  434. + int pname;
  435. if(f.is_open()) {
  436. mailcheck = askaway = false;
  437. @@ -418,10 +418,10 @@
  438. ptpmin = atoi(getword(buf, "-").c_str());
  439. ptpmax = atoi(buf.c_str());
  440. } else {
  441. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  442. - buf = getprotocolname(pname);
  443. + for(pname = icq; pname != protocolname_size; pname += 1) {
  444. + buf = getprotocolname((protocolname)pname);
  445. if(param.substr(0, buf.size()) == buf) {
  446. - im = getourid(pname);
  447. + im = getourid((protocolname)pname);
  448. im.read(rbuf);
  449. setourid(im);
  450. }
  451. @@ -430,8 +430,8 @@
  452. }
  453. if(fromcharset.empty() && tocharset.empty())
  454. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  455. - if(getcpconvert(pname)) {
  456. + for(pname = icq; pname != protocolname_size; pname += 1) {
  457. + if(getcpconvert((protocolname)pname)) {
  458. fromcharset = "cp1251";
  459. tocharset = "koi8-r";
  460. break;
  461. @@ -470,26 +470,26 @@
  462. if(getaskaway()) f << "askaway" << endl;
  463. param = "";
  464. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  465. - if(getchatmode(pname)) param += (string) " " + conf.getprotocolname(pname);
  466. + for(int pname = icq; pname != protocolname_size; pname += 1)
  467. + if(getchatmode((protocolname)pname)) param += (string) " " + conf.getprotocolname((protocolname)pname);
  468. if(!param.empty())
  469. f << "chatmode" << param << endl;
  470. param = "";
  471. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  472. - if(getentersends(pname)) param += (string) " " + conf.getprotocolname(pname);
  473. + for(int pname = icq; pname != protocolname_size; pname += 1)
  474. + if(getentersends((protocolname)pname)) param += (string) " " + conf.getprotocolname((protocolname)pname);
  475. if(!param.empty())
  476. f << "entersends" << param << endl;
  477. param = "";
  478. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  479. - if(getnonimonline(pname)) param += (string) " " + conf.getprotocolname(pname);
  480. + for(int pname = icq; pname != protocolname_size; pname += 1)
  481. + if(getnonimonline((protocolname)pname)) param += (string) " " + conf.getprotocolname((protocolname)pname);
  482. if(!param.empty())
  483. f << "nonimonline" << param << endl;
  484. param = "";
  485. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  486. - if(getcpconvert(pname)) param += (string) " " + conf.getprotocolname(pname);
  487. + for(int pname = icq; pname != protocolname_size; pname += 1)
  488. + if(getcpconvert((protocolname)pname)) param += (string) " " + conf.getprotocolname((protocolname)pname);
  489. if(!param.empty())
  490. f << "convert" << param << endl;
  491. @@ -594,7 +594,7 @@
  492. string tname = getconfigfname("sounds"), buf, suin, skey;
  493. int n, ffuin, i;
  494. icqcontact *c;
  495. - imevent::imeventtype it;
  496. + int it;
  497. typedef pair<imevent::imeventtype, string> eventsound;
  498. vector<eventsound> soundnames;
  499. @@ -609,8 +609,8 @@
  500. for(i = 0; i < clist.count; i++) {
  501. c = (icqcontact *) clist.at(i);
  502. - for(it = imevent::message; it != imevent::imeventtype_size; (int) it += 1) {
  503. - c->setsound(it, "");
  504. + for(it = imevent::message; it != imevent::imeventtype_size; it += 1) {
  505. + c->setsound((imevent::imeventtype)it, "");
  506. }
  507. }
  508. @@ -685,20 +685,20 @@
  509. suin.erase(0, i+1);
  510. imcontact ic;
  511. - protocolname pname;
  512. + int pname;
  513. - for(pname = icq; pname != protocolname_size && skey != getprotocolname(pname); (int) pname += 1);
  514. + for(pname = icq; pname != protocolname_size && skey != getprotocolname((protocolname)pname); pname += 1);
  515. if(pname != protocolname_size) {
  516. if(suin == "*") {
  517. for(i = 0; i < clist.count; i++) {
  518. c = (icqcontact *) clist.at(i);
  519. - if(c->getdesc().pname == pname) c->setsound(it, buf);
  520. + if(c->getdesc().pname == pname) c->setsound((imevent::imeventtype)it, buf);
  521. }
  522. } else {
  523. - if(pname == icq) ic = imcontact(strtoul(suin.c_str(), 0, 0), pname);
  524. - else ic = imcontact(suin, pname);
  525. + if(pname == icq) ic = imcontact(strtoul(suin.c_str(), 0, 0), (protocolname)pname);
  526. + else ic = imcontact(suin, (protocolname)pname);
  527. c = clist.get(ic);
  528. }
  529. @@ -708,7 +708,7 @@
  530. c = clist.get(contactroot);
  531. }
  532. - if(c) c->setsound(it, buf);
  533. + if(c) c->setsound((imevent::imeventtype)it, buf);
  534. }
  535. fi.close();
  536. @@ -1003,18 +1003,18 @@
  537. }
  538. imstatus icqconf::getstatus(protocolname pname) {
  539. - imstatus st = available;
  540. + int st = available;
  541. map<string, string>::iterator ia;
  542. imaccount a = getourid(pname);
  543. if((ia = a.additional.find("status")) != a.additional.end()) {
  544. if(!ia->second.empty()) {
  545. - for(st = offline; st != imstatus_size && imstatus2char[st] != ia->second[0]; (int) st += 1);
  546. + for(st = offline; st != imstatus_size && imstatus2char[st] != ia->second[0]; st += 1);
  547. if(st == imstatus_size) st = available;
  548. }
  549. }
  550. - return st;
  551. + return (imstatus)st;
  552. }
  553. void icqconf::savestatus(protocolname pname, imstatus st) {
  554. @@ -1099,8 +1099,8 @@
  555. << "Written by Konstantin Klyagin." << endl
  556. << "Built-in protocols are:";
  557. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  558. - if(gethook(pname).enabled()) cout << " " << conf.getprotocolname(pname);
  559. + for(int pname = icq; pname != protocolname_size; pname += 1)
  560. + if(gethook((protocolname)pname).enabled()) cout << " " << conf.getprotocolname((protocolname)pname);
  561. cout << endl << endl
  562. << "This is free software; see the source for copying conditions. There is NO" << endl
  563. @@ -1150,11 +1150,11 @@
  564. }
  565. cdest = imcontact(strtoul(dest.c_str(), 0, 0), icq);
  566. } else {
  567. - protocolname pname;
  568. + int pname;
  569. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  570. - if(getprotocolname(pname) == proto) {
  571. - cdest = imcontact(dest, pname);
  572. + for(pname = icq; pname != protocolname_size; pname += 1) {
  573. + if(getprotocolname((protocolname)pname) == proto) {
  574. + cdest = imcontact(dest, (protocolname)pname);
  575. break;
  576. }
  577. }
  578. @@ -1212,16 +1212,16 @@
  579. }
  580. void icqconf::externalstatuschange(char st, const string &proto) const {
  581. - imstatus imst;
  582. - protocolname pname;
  583. + int imst;
  584. + int pname;
  585. if(st) {
  586. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  587. - if(getprotocolname(pname) == proto)
  588. + for(pname = icq; pname != protocolname_size; pname += 1)
  589. + if(getprotocolname((protocolname)pname) == proto)
  590. break;
  591. - for(imst = offline; imst != imstatus_size; (int) imst += 1)
  592. + for(imst = offline; imst != imstatus_size; imst += 1)
  593. if(imstatus2char[imst] == st)
  594. break;
  595. @@ -1317,16 +1317,16 @@
  596. void icqconf::initmultiproto(bool p[], string buf, bool excludenochat) {
  597. string w;
  598. - protocolname pname;
  599. + int pname;
  600. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  601. + for(pname = icq; pname != protocolname_size; pname += 1)
  602. p[pname] = buf.empty();
  603. while(!(w = getword(buf)).empty()) {
  604. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  605. - if(getprotocolname(pname) == w) {
  606. + for(pname = icq; pname != protocolname_size; pname += 1) {
  607. + if(getprotocolname((protocolname)pname) == w) {
  608. if(excludenochat) {
  609. - p[pname] = !gethook(pname).getCapabs().count(hookcapab::nochat);
  610. + p[pname] = !gethook((protocolname)pname).getCapabs().count(hookcapab::nochat);
  611. } else {
  612. p[pname] = true;
  613. }
  614. --- ./src/icqcontact.cc.orig 2004-04-11 19:32:27.000000000 +0300
  615. +++ ./src/icqcontact.cc 2004-05-04 12:29:40.598254376 +0300
  616. @@ -48,8 +48,10 @@
  617. finlist = true;
  618. congratulated = false;
  619. - for(ie = imevent::message; ie != imevent::imeventtype_size; (int) ie += 1)
  620. - sound[ie] = "";
  621. + int int_ie;
  622. + for(int_ie = imevent::message; int_ie != imevent::imeventtype_size; int_ie += 1)
  623. + sound[(imevent::imeventtype)int_ie] = "";
  624. + ie = (imevent::imeventtype)int_ie;
  625. cdesc = adesc;
  626. --- ./src/icqdialogs.cc.orig 2004-04-01 11:01:13.000000000 +0300
  627. +++ ./src/icqdialogs.cc 2004-05-04 12:40:26.961992152 +0300
  628. @@ -174,13 +174,13 @@
  629. imsearchparams ts;
  630. if(subj != fsrss) {
  631. - for(protocolname apname = icq; apname != protocolname_size; (int) apname += 1) {
  632. + for(int apname = icq; apname != protocolname_size; apname += 1) {
  633. if(subj == fschannel)
  634. - if(!gethook(apname).getCapabs().count(hookcapab::conferencing))
  635. + if(!gethook((protocolname)apname).getCapabs().count(hookcapab::conferencing))
  636. continue;
  637. - if(gethook(apname).logged() || apname == infocard) {
  638. - penabled.push_back(apname);
  639. + if(gethook((protocolname)apname).logged() || apname == infocard) {
  640. + penabled.push_back((protocolname)apname);
  641. }
  642. }
  643. @@ -937,8 +937,8 @@
  644. m.setwindow(textwindow(4, LINES-8, 20, LINES-4, conf.getcolor(cp_dialog_menu)));
  645. m.idle = &menuidle;
  646. - for(imgender i = genderUnspec; i != imgender_size; (int) i += 1) {
  647. - m.additemf(0, (int) i, " %s", strgender(i));
  648. + for(int i = genderUnspec; i != imgender_size; i += 1) {
  649. + m.additemf(0, i, " %s", strgender((imgender)i));
  650. if(i == f) m.setpos(m.getcount()-1);
  651. }
  652. @@ -953,13 +953,13 @@
  653. m.setwindow(textwindow(4, LINES-8, 18, LINES-3, conf.getcolor(cp_dialog_menu)));
  654. m.idle = &menuidle;
  655. - for(ICQ2000::AgeRange i = ICQ2000::RANGE_NORANGE; i <= ICQ2000::RANGE_60_ABOVE; (int) i += 1) {
  656. - const char *p = stragerange(i);
  657. + for(int i = ICQ2000::RANGE_NORANGE; i <= ICQ2000::RANGE_60_ABOVE; i += 1) {
  658. + const char *p = stragerange((ICQ2000::AgeRange)i);
  659. if(i == ICQ2000::RANGE_NORANGE)
  660. p = _("none");
  661. - m.additemf(0, (int) i, " %s", p);
  662. + m.additemf(0, i, " %s", p);
  663. if(i == r) m.setpos(m.getcount()-1);
  664. }
  665. @@ -1071,14 +1071,14 @@
  666. }
  667. void icqface::multichange(bool conv[], bool newstate) {
  668. - protocolname pname;
  669. + int pname;
  670. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  671. - if((!conf.getourid(pname).empty() || pname == rss) && conv[pname]) break;
  672. + for(pname = icq; pname != protocolname_size; pname += 1)
  673. + if((!conf.getourid((protocolname)pname).empty() || pname == rss) && conv[pname]) break;
  674. if(pname == protocolname_size || !newstate) {
  675. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  676. - if(!conf.getourid(pname).empty() || pname == rss)
  677. + for(pname = icq; pname != protocolname_size; pname += 1)
  678. + if(!conf.getourid((protocolname)pname).empty() || pname == rss)
  679. conv[pname] = newstate;
  680. }
  681. }
  682. @@ -1086,7 +1086,7 @@
  683. bool icqface::updateconf(icqconf::regsound &s, icqconf::regcolor &c) {
  684. bool finished, success, hasany;
  685. int nopt, n, i, b, nconf, ncomm, aaway, ana, noth, nfeat, ncl;
  686. - protocolname pname;
  687. + int pname;
  688. string tmp, phidden;
  689. string smtp = conf.getsmtphost() + ":" + i2str(conf.getsmtpport());
  690. @@ -1134,15 +1134,15 @@
  691. bool chatmode[protocolname_size], conv[protocolname_size],
  692. entersends[protocolname_size], nonimonline[protocolname_size];
  693. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  694. - chatmode[pname] = conf.getchatmode(pname);
  695. - entersends[pname] = conf.getentersends(pname);
  696. - conv[pname] = conf.getcpconvert(pname);
  697. - nonimonline[pname] = conf.getnonimonline(pname);
  698. + for(pname = icq; pname != protocolname_size; pname += 1) {
  699. + chatmode[pname] = conf.getchatmode((protocolname)pname);
  700. + entersends[pname] = conf.getentersends((protocolname)pname);
  701. + conv[pname] = conf.getcpconvert((protocolname)pname);
  702. + nonimonline[pname] = conf.getnonimonline((protocolname)pname);
  703. }
  704. - for(hasany = false, pname = icq; pname != protocolname_size && !hasany; (int) pname += 1)
  705. - hasany = !conf.getourid(pname).empty();
  706. + for(hasany = false, pname = icq; pname != protocolname_size && !hasany; pname += 1)
  707. + hasany = !conf.getourid((protocolname)pname).empty();
  708. dialogbox db;
  709. @@ -1184,10 +1184,10 @@
  710. i = t.addnode(_(" Codepages conversion "));
  711. - for(tmp = "", pname = icq; pname != protocolname_size; (int) pname += 1)
  712. + for(tmp = "", pname = icq; pname != protocolname_size; pname += 1)
  713. if(conv[pname])
  714. - if(!conf.getourid(pname).empty() || pname == rss)
  715. - tmp += conf.getprotocolname(pname) + " ";
  716. + if(!conf.getourid((protocolname)pname).empty() || pname == rss)
  717. + tmp += conf.getprotocolname((protocolname)pname) + " ";
  718. t.addleaff(i, 0, 26, _(" Switch to language preset : %s "), iconvlang->c_str());
  719. t.addleaff(i, 0, 27, _(" Convert from : %s "), convertfrom.c_str());
  720. @@ -1207,15 +1207,15 @@
  721. t.addleaff(i, 0, 7, _(" Edit away message on status change : %s "), stryesno(askaway));
  722. if(hasany) {
  723. - for(tmp = "", pname = icq; pname != protocolname_size; (int) pname += 1)
  724. - if(chatmode[pname] && !conf.getourid(pname).empty())
  725. - tmp += conf.getprotocolname(pname) + " ";
  726. + for(tmp = "", pname = icq; pname != protocolname_size; pname += 1)
  727. + if(chatmode[pname] && !conf.getourid((protocolname)pname).empty())
  728. + tmp += conf.getprotocolname((protocolname)pname) + " ";
  729. t.addleaff(i, 0, 16, _(" Chat messaging mode for : %s"), tmp.c_str());
  730. - for(tmp = "", pname = icq; pname != protocolname_size; (int) pname += 1)
  731. - if(entersends[pname] && !conf.getourid(pname).empty())
  732. - tmp += conf.getprotocolname(pname) + " ";
  733. + for(tmp = "", pname = icq; pname != protocolname_size; pname += 1)
  734. + if(entersends[pname] && !conf.getourid((protocolname)pname).empty())
  735. + tmp += conf.getprotocolname((protocolname)pname) + " ";
  736. t.addleaff(i, 0, 25, _(" Enter key sends message for : %s"), tmp.c_str());
  737. @@ -1225,8 +1225,8 @@
  738. }
  739. - for(tmp = "", pname = icq; pname != protocolname_size; (int) pname += 1)
  740. - if(nonimonline[pname]) tmp += conf.getprotocolname(pname) + " ";
  741. + for(tmp = "", pname = icq; pname != protocolname_size; pname += 1)
  742. + if(nonimonline[pname]) tmp += conf.getprotocolname((protocolname)pname) + " ";
  743. t.addleaff(i, 0, 29, _(" Always online non-IM contacts for : %s"), tmp.c_str());
  744. @@ -1272,7 +1272,7 @@
  745. break;
  746. case 3:
  747. if(hasany) selectproto(conv, spIMplusRSS); else
  748. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  749. + for(pname = icq; pname != protocolname_size; pname += 1)
  750. conv[pname] = !conv[pname];
  751. break;
  752. case 4:
  753. @@ -1264,7 +1264,7 @@
  754. case 15: mailcheck = !mailcheck; break;
  755. case 16:
  756. if(hasany) selectproto(chatmode); else
  757. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  758. + for(pname = icq; pname != protocolname_size; pname += 1)
  759. chatmode[pname] = !chatmode[pname];
  760. break;
  761. @@ -1328,7 +1328,7 @@
  762. break;
  763. case 25:
  764. if(hasany) selectproto(entersends); else
  765. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  766. + for(pname = icq; pname != protocolname_size; pname += 1)
  767. entersends[pname] = !entersends[pname];
  768. break;
  769. case 26:
  770. @@ -1381,13 +1381,13 @@
  771. conf.setaskaway(askaway);
  772. conf.setcharsets(convertfrom, convertto);
  773. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  774. - conf.setchatmode(pname, chatmode[pname]);
  775. - conf.setentersends(pname, entersends[pname]);
  776. - conf.setnonimonline(pname, nonimonline[pname]);
  777. + for(pname = icq; pname != protocolname_size; pname += 1) {
  778. + conf.setchatmode((protocolname)pname, chatmode[pname]);
  779. + conf.setentersends((protocolname)pname, entersends[pname]);
  780. + conf.setnonimonline((protocolname)pname, nonimonline[pname]);
  781. bool bconv = conv[pname] && (!convertfrom.empty() || !convertto.empty());
  782. - conf.setcpconvert(pname, bconv || !hasany);
  783. + conf.setcpconvert((protocolname)pname, bconv || !hasany);
  784. }
  785. conf.setbidi(bidi);
  786. @@ -1419,17 +1419,17 @@
  787. int i, protmax;
  788. bool r, finished = false;
  789. - protocolname pname;
  790. + int pname;
  791. protocolname tempprots[protocolname_size];
  792. bool aprots[protocolname_size];
  793. i = 0;
  794. memcpy(aprots, prots, sizeof(aprots));
  795. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  796. + for(pname = icq; pname != protocolname_size; pname += 1) {
  797. if(mode == spnonIM) {
  798. if(pname != infocard)
  799. - if(!gethook(pname).getCapabs().count(hookcapab::nochat))
  800. + if(!gethook((protocolname)pname).getCapabs().count(hookcapab::nochat))
  801. continue;
  802. if(pname == livejournal)
  803. @@ -1438,19 +1438,19 @@
  804. } else {
  805. if(mode != spIMplusRSS || pname != rss)
  806. if(pname != livejournal || mode == spIMonly) {
  807. - if(gethook(pname).getCapabs().count(hookcapab::nochat))
  808. + if(gethook((protocolname)pname).getCapabs().count(hookcapab::nochat))
  809. continue;
  810. - if(conf.getourid(pname).empty())
  811. + if(conf.getourid((protocolname)pname).empty())
  812. continue;
  813. }
  814. - if(!gethook(pname).enabled())
  815. + if(!gethook((protocolname)pname).enabled())
  816. continue;
  817. }
  818. - tempprots[i++] = pname;
  819. + tempprots[i++] = (protocolname)pname;
  820. }
  821. protmax = i;
  822. --- ./src/icqface.cc.orig 2004-04-11 19:32:28.000000000 +0300
  823. +++ ./src/icqface.cc 2004-05-04 13:29:21.551866680 +0300
  824. @@ -205,16 +205,16 @@
  825. void icqface::showtopbar() {
  826. string buf;
  827. - protocolname pname;
  828. + int pname;
  829. icqconf::imaccount ia;
  830. - for(pname = icq; pname != protocolname_size; (int) pname += 1) {
  831. - ia = conf.getourid(pname);
  832. + for(pname = icq; pname != protocolname_size; pname += 1) {
  833. + ia = conf.getourid((protocolname)pname);
  834. if(!ia.empty()) {
  835. buf += " ";
  836. - buf += conf.getprotocolname(pname) + ":";
  837. - buf += imstatus2char[gethook(pname).getstatus()];
  838. + buf += conf.getprotocolname((protocolname)pname) + ":";
  839. + buf += imstatus2char[gethook((protocolname)pname).getstatus()];
  840. // buf += ">";
  841. }
  842. }
  843. @@ -1305,7 +1305,7 @@
  844. void icqface::makeprotocolmenu(verticalmenu &m) {
  845. icqconf::imaccount ia;
  846. - protocolname ipname;
  847. + int ipname;
  848. static const string pitems[protocolname_size] = {
  849. _(" [icq] ICQ network"),
  850. @@ -1320,11 +1320,11 @@
  851. ""
  852. };
  853. - for(ipname = icq; ipname != protocolname_size; (int) ipname += 1) {
  854. - ia = conf.getourid(ipname);
  855. + for(ipname = icq; ipname != protocolname_size; ipname += 1) {
  856. + ia = conf.getourid((protocolname)ipname);
  857. if(!ia.empty()) {
  858. - m.additem(0, ipname, pitems[ipname]);
  859. + m.additem(0, (protocolname)ipname, pitems[ipname]);
  860. }
  861. }
  862. }
  863. @@ -1336,20 +1336,21 @@
  864. vector<imstatus> mst;
  865. vector<imstatus>::iterator im;
  866. - protocolname pname, onechoice;
  867. + int pname;
  868. + protocolname onechoice;
  869. m.setwindow(textwindow(sizeWArea.x1, sizeWArea.y1, sizeWArea.x1+27,
  870. sizeWArea.y1+9, conf.getcolor(cp_main_text)));
  871. m.idle = &menuidle;
  872. - for(protcount = 0, pname = icq; pname != protocolname_size; (int) pname += 1) {
  873. - if(!conf.getourid(pname).empty()) {
  874. + for(protcount = 0, pname = icq; pname != protocolname_size; pname += 1) {
  875. + if(!conf.getourid((protocolname)pname).empty()) {
  876. protcount++;
  877. - onechoice = pname;
  878. + onechoice = (protocolname)pname;
  879. }
  880. - alrlogged = alrlogged || gethook(pname).getstatus() != offline;
  881. + alrlogged = alrlogged || gethook((protocolname)pname).getstatus() != offline;
  882. }
  883. if(protcount < 2) {
  884. @@ -1372,15 +1370,15 @@
  885. if(r = i) {
  886. switch(choice) {
  887. case -1:
  888. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  889. - if(!conf.getourid(pname).empty())
  890. - pnames.push_back(pname);
  891. + for(pname = icq; pname != protocolname_size; pname += 1)
  892. + if(!conf.getourid((protocolname)pname).empty())
  893. + pnames.push_back((protocolname)pname);
  894. break;
  895. case -2:
  896. - for(pname = icq; pname != protocolname_size; (int) pname += 1)
  897. - if(!conf.getourid(pname).empty())
  898. - if(gethook(pname).getstatus() != offline)
  899. - pnames.push_back(pname);
  900. + for(pname = icq; pname != protocolname_size; pname += 1)
  901. + if(!conf.getourid((protocolname)pname).empty())
  902. + if(gethook((protocolname)pname).getstatus() != offline)
  903. + pnames.push_back((protocolname)pname);
  904. break;
  905. default:
  906. pnames.push_back((protocolname) choice);
  907. @@ -1658,9 +1659,9 @@
  908. set<protocolname> ps;
  909. if(cs == csvisible || cs == csinvisible) {
  910. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  911. - if(gethook(pname).getCapabs().count(hookcapab::visibility))
  912. - ps.insert(pname);
  913. + for(int pname = icq; pname != protocolname_size; pname += 1)
  914. + if(gethook((protocolname)pname).getCapabs().count(hookcapab::visibility))
  915. + ps.insert((protocolname)pname);
  916. }
  917. lst.fillmenu(db.getmenu(), cs);
  918. --- ./src/icqgroup.cc.orig 2003-11-22 21:14:33.000000000 +0200
  919. +++ ./src/icqgroup.cc 2004-05-04 13:30:37.417333376 +0300
  920. @@ -82,6 +82,6 @@
  921. string oldname = name;
  922. name = aname;
  923. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1)
  924. - gethook(pname).renamegroup(oldname, name);
  925. + for(int pname = icq; pname != protocolname_size; pname += 1)
  926. + gethook((protocolname)pname).renamegroup(oldname, name);
  927. }
  928. --- ./src/imevents.cc.orig 2004-04-11 19:32:28.000000000 +0300
  929. +++ ./src/imevents.cc 2004-05-04 13:24:29.099326224 +0300
  930. @@ -62,11 +62,11 @@
  931. }
  932. imevent::imeventtype imevent::gettype() const {
  933. - return type;
  934. + return (imevent::imeventtype)type;
  935. }
  936. imevent::imdirection imevent::getdirection() const {
  937. - return direction;
  938. + return (imevent::imdirection)direction;
  939. }
  940. imcontact imevent::getcontact() const {
  941. @@ -111,14 +111,14 @@
  942. if(rdbuf == "\f")
  943. getstring(f, rdbuf);
  944. - for(direction = incoming; direction != imdirection_size; (int) direction += 1)
  945. + for(direction = incoming; direction != imdirection_size; direction += 1)
  946. if(sdirection[direction] == rdbuf) break;
  947. getstring(f, rdbuf);
  948. type = imeventtype_size;
  949. if(rdbuf != "") {
  950. - for(type = message; type != imeventtype_size; (int) type += 1)
  951. + for(type = message; type != imeventtype_size; type += 1)
  952. if(seventtype[type] == rdbuf) break;
  953. }
  954. --- ./src/imevents.h.orig 2004-02-21 18:15:05.000000000 +0200
  955. +++ ./src/imevents.h 2004-05-04 13:19:30.965649432 +0300
  956. @@ -30,8 +30,8 @@
  957. protected:
  958. imcontact contact;
  959. - imeventtype type;
  960. - imdirection direction;
  961. + int type;
  962. + int direction;
  963. time_t senttimestamp;
  964. time_t timestamp;
  965. --- ./src/imexternal.cc.orig 2004-03-20 18:49:08.000000000 +0200
  966. +++ ./src/imexternal.cc 2004-05-04 12:42:57.835055960 +0300
  967. @@ -393,20 +393,20 @@
  968. if(param == "event") {
  969. while(!(param = getword(buf)).empty()) {
  970. - for(imevent::imeventtype et = imevent::message; et != imevent::imeventtype_size; (int) et += 1) {
  971. - if((param == geteventname(et))
  972. + for(int et = imevent::message; et != imevent::imeventtype_size; et += 1) {
  973. + if((param == geteventname((imevent::imeventtype)et))
  974. || (param == "all")) {
  975. - event.insert(et);
  976. + event.insert((imevent::imeventtype)et);
  977. }
  978. }
  979. }
  980. } else if(param == "proto") {
  981. while(!(param = getword(buf)).empty()) {
  982. - for(protocolname pname = icq; pname != protocolname_size; (int) pname += 1) {
  983. - if((param == conf.getprotocolname(pname))
  984. + for(int pname = icq; pname != protocolname_size; pname += 1) {
  985. + if((param == conf.getprotocolname((protocolname)pname))
  986. || (param == "all")) {
  987. - proto.insert(pname);
  988. + proto.insert((protocolname)pname);
  989. }
  990. }
  991. }