You can subscribe to this list here.
2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(106) |
Oct
(334) |
Nov
(246) |
Dec
(145) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2002 |
Jan
(42) |
Feb
(53) |
Mar
(232) |
Apr
(109) |
May
(137) |
Jun
(63) |
Jul
(26) |
Aug
(263) |
Sep
(193) |
Oct
(507) |
Nov
(440) |
Dec
(241) |
2003 |
Jan
(567) |
Feb
(195) |
Mar
(504) |
Apr
(481) |
May
(524) |
Jun
(522) |
Jul
(594) |
Aug
(502) |
Sep
(643) |
Oct
(508) |
Nov
(430) |
Dec
(377) |
2004 |
Jan
(361) |
Feb
(251) |
Mar
(219) |
Apr
(499) |
May
(461) |
Jun
(419) |
Jul
(314) |
Aug
(519) |
Sep
(416) |
Oct
(247) |
Nov
(305) |
Dec
(382) |
2005 |
Jan
(267) |
Feb
(282) |
Mar
(327) |
Apr
(338) |
May
(189) |
Jun
(400) |
Jul
(462) |
Aug
(530) |
Sep
(316) |
Oct
(523) |
Nov
(481) |
Dec
(650) |
2006 |
Jan
(536) |
Feb
(361) |
Mar
(287) |
Apr
(146) |
May
(101) |
Jun
(169) |
Jul
(221) |
Aug
(498) |
Sep
(300) |
Oct
(236) |
Nov
(209) |
Dec
(205) |
2007 |
Jan
(30) |
Feb
(23) |
Mar
(26) |
Apr
(15) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Eric W. <war...@us...> - 2001-10-05 06:37:37
|
Update of /cvsroot/gaim/gaim In directory usw-pr-cvs1:/tmp/cvs-serv15589 Modified Files: ChangeLog NEWS Log Message: sorry rob, i waited patiently for you Index: ChangeLog =================================================================== RCS file: /cvsroot/gaim/gaim/ChangeLog,v retrieving revision 1.308 retrieving revision 1.309 diff -u -d -r1.308 -r1.309 --- ChangeLog 2001/10/02 16:39:00 1.308 +++ ChangeLog 2001/10/05 06:37:34 1.309 @@ -1,6 +1,6 @@ GAIM: The Pimpin' Penguin IM Clone thats good for the soul! -version 0.45: +version 0.45 (10/04/2001): * New plugin event: event_chat_send_invite * Major updates to the perl system (reread PERL-HOWTO and SIGNALS) Index: NEWS =================================================================== RCS file: /cvsroot/gaim/gaim/NEWS,v retrieving revision 1.89 retrieving revision 1.90 diff -u -d -r1.89 -r1.90 --- NEWS 2001/09/20 18:06:06 1.89 +++ NEWS 2001/10/05 06:37:34 1.90 @@ -1,5 +1,14 @@ -=[ GAIM ]=- The Pimpin' Penguin AIM Clone That's Good For The Soul! +0.45 (10/04/2001): + Eric: Well, it seems that the time has come for yet another + release. There are several yummy additions in this release, and + quite a few useful bugfixes as well. Unfortunately it seems that + Rob is currently unavailable; he joins us in spirit. He'll be + joining us later for a group sing-along and smores by the + campfire. But for now, you'll need to keep yourselves occupied + with 0.45. And remember, a happy hacker is a pimpin' penguin. + 0.44 (09/20/2001): Rob: Another release has come upon us. There were actually quite a number of things in ye old ChangeLog for this release. I don't |
From: Eric W. <war...@us...> - 2001-10-04 23:10:56
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv28056 Modified Files: prpl.c Log Message: one bug down, several to go. Index: prpl.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/prpl.c,v retrieving revision 1.37 retrieving revision 1.38 diff -u -d -r1.37 -r1.38 --- prpl.c 2001/10/03 09:48:33 1.37 +++ prpl.c 2001/10/04 23:10:51 1.38 @@ -362,7 +362,11 @@ static void des_email_win(GtkWidget *w, struct mail_notify *mn) { - gtk_widget_destroy(mn->email_win); + if (w != mn->email_win) { + gtk_widget_destroy(mn->email_win); + return; + } + debug_printf("removing mail notification\n"); mailnots = g_slist_remove(mailnots, mn); g_free(mn); } |
From: Eric W. <war...@us...> - 2001-10-04 19:36:52
|
Update of /cvsroot/gaim/gaim/src/protocols/oscar In directory usw-pr-cvs1:/tmp/cvs-serv11272/protocols/oscar Modified Files: oscar.c Log Message: fix solaris Index: oscar.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/oscar.c,v retrieving revision 1.43 retrieving revision 1.44 diff -u -d -r1.43 -r1.44 --- oscar.c 2001/10/03 20:36:33 1.43 +++ oscar.c 2001/10/04 19:36:49 1.44 @@ -1935,11 +1935,13 @@ params = va_arg(ap, struct aim_icbmparameters *); va_end(ap); + /* evidently this crashes on solaris. i have no clue why debug_printf("ICBM Parameters: maxchannel = %d, default flags = 0x%08lx, max msg len = %d, " "max sender evil = %f, max receiver evil = %f, min msg interval = %ld\n", params->maxchan, params->flags, params->maxmsglen, ((float)params->maxsenderwarn)/10.0, ((float)params->maxrecverwarn)/10.0, params->minmsginterval); + */ /* Maybe senderwarn and recverwarn should be user preferences... */ params->maxmsglen = 8000; |
From: Rob F. <rob...@us...> - 2001-10-04 15:57:14
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv14233/src Modified Files: conversation.c Log Message: Nothing here, just fixed a typo. Stop reading this. Delete this message now. Index: conversation.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/conversation.c,v retrieving revision 1.271 retrieving revision 1.272 diff -u -d -r1.271 -r1.272 --- conversation.c 2001/10/03 20:36:33 1.271 +++ conversation.c 2001/10/04 15:57:10 1.272 @@ -58,6 +58,7 @@ #include "pixmaps/oneeye.xpm" #include "pixmaps/crazy4.xpm" #include "pixmaps/mrt.xpm" +#include "pixmaps/download.xpm" int state_lock = 0; @@ -100,6 +101,7 @@ gtk_imhtml_associate_smiley(GTK_IMHTML(imhtml), ">:-)", crazy4_xpm); gtk_imhtml_associate_smiley(GTK_IMHTML(imhtml), ":-o)))", mrt_xpm); gtk_imhtml_associate_smiley(GTK_IMHTML(imhtml), ":-O)))", mrt_xpm); + gtk_imhtml_associate_smiley(GTK_IMHTML(imhtml), "8-|)", download_xpm); } void quiet_set(GtkWidget *tb, int state) |
From: Rob F. <rob...@us...> - 2001-10-04 15:57:14
|
Update of /cvsroot/gaim/gaim/pixmaps In directory usw-pr-cvs1:/tmp/cvs-serv14233/pixmaps Modified Files: Makefile.am Added Files: download.xpm Log Message: Nothing here, just fixed a typo. Stop reading this. Delete this message now. --- NEW FILE: download.xpm --- /* XPM */ static char * download_xpm[] = { "18 18 257 2", " c None", ". c #C6A56B", "+ c #6F3D17", "@ c #6D3C16", "# c #6B3B15", "$ c #603310", "% c #62340F", "& c #623512", "* c #D5B173", "= c #CBA96E", "- c #683914", "; c #0000FF", "> c #24170D", ", c #6767FF", "' c #2A190B", ") c #766340", "! c #4F2B0F", "~ c #9A8154", "{ c #CEAC70", "] c #6C685E", "^ c #7B5F39", "/ c #C1A168", "( c #646566", "_ c #BD9F67", ": c #8D7448", "< c #C7A569", "[ c #4F2A0E", "} c #643510", "| c #4E280B", "1 c #56462A", "2 c #6C5B3C", "3 c #673812", "4 c #6A3A14", "5 c #6C5C3C", "6 c #603411", "7 c #733F18", "8 c #D0AD71", "9 c #643713", "0 c #4F2708", "a c #DBB676", "b c #5D3412", "c c #693A13", "d c #957B4D", "e c #CDAB6F", "f c #937849", "g c #B8945E", "h c #6B3B14", "i c #673813", "j c #633E1C", "k c #5C2E0A", "l c #80693F", "m c #6C3C16", "n c #CAA86D", "o c #AB8D58", "p c #493D27", "q c #886D3E", "r c #A38551", "s c #5B2E0A", "t c #9E8354", "u c #8A754C", "v c #5E320E", "w c #524227", "x c #423620", "y c #070300", "z c #907649", "A c #2B2518", "B c #A48857", "C c #D4B072", "D c #7C6743", "E c #713E18", "F c #372F1F", "G c #5F3411", "H c #292420", "I c #BF9E64", "J c #474542", "K c #D7B375", "L c #877047", "M c #552D0E", "N c #50290A", "O c #52381C", "P c #6E5C3B", "Q c #8E764C", "R c #2F2015", "S c #A18657", "T c #653713", "U c #484B50", "V c #6A3B14", "W c #AA8D59", "X c #432005", "Y c #623612", "Z c #DAB677", "` c #5D300C", " . c #60320E", ".. c #B39560", "+. c #2A1606", "@. c #080401", "#. c #2D1400", "$. c #352D1E", "%. c #C7A66B", "&. c #7A6640", "*. c #B39561", "=. c #6A3A13", "-. c #693913", ";. c #5A300F", ">. c #543D22", ",. c #937A4D", "'. c #060606", "). c #827F76", "!. c #BD9C62", "~. c #967B4B", "{. c #836D47", "]. c #653712", "^. c #C9A76B", "/. c #C7A66C", "(. c #A48754", "_. c #8B744B", ":. c #58554E", "<. c #754118", "[. c #A4A4FF", "}. c #D4AF6E", "|. c #3D3424", "1. c #D0AD70", "2. c #9A8053", "3. c #AB8C57", "4. c #675537", "5. c #B69762", "6. c #725F3D", "7. c #663813", "8. c #8B7147", "9. c #DBB674", "0. c #A1A4A6", "a. c #180400", "b. c #06090B", "c. c #ADADFF", "d. c #432E18", "e. c #FFFFFF", "f. c #000000", "g. c #FFFFFF", "h. c #000000", "i. c #000000", "j. c #000000", "k. c #000000", "l. c #000000", "m. c #000000", "n. c #000000", "o. c #000000", "p. c #000000", "q. c #000000", "r. c #000000", "s. c #000000", "t. c #000000", "u. c #000000", "v. c #000000", "w. c #000000", "x. c #000000", "y. c #000000", "z. c #000000", "A. c #000000", "B. c #000000", "C. c #000000", "D. c #000000", "E. c #000000", "F. c #000000", "G. c #000000", "H. c #000000", "I. c #000000", "J. c #000000", "K. c #000000", "L. c #000000", "M. c #000000", "N. c #000000", "O. c #000000", "P. c #000000", "Q. c #000000", "R. c #000000", "S. c #000000", "T. c #000000", "U. c #000000", "V. c #000000", "W. c #000000", "X. c #000000", "Y. c #000000", "Z. c #000000", "`. c #000000", " + c #000000", ".+ c #000000", "++ c #000000", "@+ c #000000", "#+ c #000000", "$+ c #000000", "%+ c #000000", "&+ c #000000", "*+ c #000000", "=+ c #000000", "-+ c #000000", ";+ c #000000", ">+ c #000000", ",+ c #000000", "'+ c #000000", ")+ c #000000", "!+ c #000000", "~+ c #000000", "{+ c #000000", "]+ c #000000", "^+ c #000000", "/+ c #000000", "(+ c #000000", "_+ c #000000", ":+ c #000000", "<+ c #000000", "[+ c #000000", "}+ c #000000", "|+ c #000000", "1+ c #000000", "2+ c #000000", "3+ c #000000", "4+ c #000000", "5+ c #000000", "6+ c #000000", "7+ c #000000", "8+ c #000000", "9+ c #000000", "0+ c #000000", "a+ c #000000", "b+ c #000000", "c+ c #000000", "d+ c #000000", "e+ c #000000", "f+ c #000000", "g+ c #000000", "h+ c #000000", "i+ c #000000", "j+ c #000000", "k+ c #000000", "l+ c #000000", "m+ c #000000", "n+ c #000000", "o+ c #000000", "p+ c #000000", "q+ c #000000", "r+ c #000000", "s+ c #000000", "t+ c #000000", "u+ c #000000", "v+ c #000000", "w+ c #000000", "x+ c #000000", "y+ c #000000", "z+ c #000000", "A+ c #000000", "B+ c #000000", "C+ c #000000", "D+ c #000000", "E+ c #000000", "F+ c #000000", "G+ c #000000", "H+ c #000000", " ", " H+H+H+H+ ", " H+H+ H+H+X $ h =.H+ ", " d.z f H+H+s ].4 # @ @ .H+ ", " d.L P ~ 8.| 9 + & M ! b c H+d.d. ", "d.W {.D $.^ G T 7.N H b.@.6 H+x q d.", "d.^.2.p F >.Y + - #.0.e.H++.y H+,.d.", "d.< 4.Q 5 O $ 7 } ' e.e.e.'.e.).l d.", "d.o 5.*.) j -.<.G X c.; e.0.c.] d. ", " d.9.Z g & i @ % > H H e.; 0.R d. ", " d.6.d.3 + + [ b.J 2.r m @.U ", " H+0 m # ;.H+_ * = / ..t H+ ", " H+k E # H+2 * . /./.{ 8 : H+ ", " H+v - V H+u 8 /.. n H+H+H+H+ ", " H+H+` a.&.K . . H+S _.}.H+ ", " H+H+H+r C = %.= a (.H+ ", " H+H+3.I !.~.H+ ", " H+H+H+H+ "}; Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/pixmaps/Makefile.am,v retrieving revision 1.56 retrieving revision 1.57 diff -u -d -r1.56 -r1.57 --- Makefile.am 2001/09/29 23:06:30 1.56 +++ Makefile.am 2001/10/04 15:57:10 1.57 @@ -27,6 +27,7 @@ crossedlips.xpm \ cry.xpm \ dt_icon.xpm \ + download.xpm \ embarrassed.xpm \ exit_small.xpm \ fgcolor.xpm \ |
From: Eric W. <war...@us...> - 2001-10-04 07:47:59
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv28417 Modified Files: Makefile.am Log Message: forgot this too. Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/Makefile.am,v retrieving revision 1.42 retrieving revision 1.43 diff -u -d -r1.42 -r1.43 --- Makefile.am 2001/10/04 07:46:58 1.42 +++ Makefile.am 2001/10/04 07:47:56 1.43 @@ -85,4 +85,5 @@ gtkticker.h \ multi.h \ prpl.h \ - proxy.h + proxy.h \ + ui.h |
From: Eric W. <war...@us...> - 2001-10-04 07:47:04
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv28204 Modified Files: Makefile.am Log Message: forgot this. Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/Makefile.am,v retrieving revision 1.41 retrieving revision 1.42 diff -u -d -r1.41 -r1.42 --- Makefile.am 2001/10/03 07:49:38 1.41 +++ Makefile.am 2001/10/04 07:46:58 1.42 @@ -75,6 +75,7 @@ EXTRA_DIST = applet.h \ convo.h \ + core.h \ gaim.h \ getopt.c \ getopt.h \ |
From: Eric W. <war...@us...> - 2001-10-04 05:45:20
|
Update of /cvsroot/gaim/gaim/src/protocols/zephyr In directory usw-pr-cvs1:/tmp/cvs-serv5028/zephyr Modified Files: Makefile.am Log Message: able to compile gg and zephyr statically. Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/Makefile.am,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- Makefile.am 2001/10/03 19:38:28 1.3 +++ Makefile.am 2001/10/04 05:45:18 1.4 @@ -59,6 +59,7 @@ ZSubs.c \ ZVariables.c \ ZWait4Not.c \ + ZhmStat.c \ Zinternal.c \ com_err.h \ error_message.c \ |
From: Eric W. <war...@us...> - 2001-10-04 05:45:20
|
Update of /cvsroot/gaim/gaim/src/protocols/gg In directory usw-pr-cvs1:/tmp/cvs-serv5028/gg Modified Files: gg.c Log Message: able to compile gg and zephyr statically. Index: gg.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/gg/gg.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- gg.c 2001/09/29 23:06:30 1.1 +++ gg.c 2001/10/04 05:45:17 1.2 @@ -969,7 +969,7 @@ static struct prpl *my_protocol = NULL; -void agg_init(struct prpl *ret) +void gg_init(struct prpl *ret) { ret->protocol = PROTO_GADUGADU; ret->options = 0; @@ -1016,7 +1016,7 @@ char *gaim_plugin_init(GModule *handle) { - load_protocol(agg_init, sizeof(struct prpl)); + load_protocol(gg_init, sizeof(struct prpl)); return NULL; } |
From: Eric W. <war...@us...> - 2001-10-04 00:05:21
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv29339 Modified Files: module.c Log Message: pass gc->away in events. Index: module.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/module.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- module.c 2001/10/03 03:11:37 1.3 +++ module.c 2001/10/04 00:05:18 1.4 @@ -430,9 +430,12 @@ switch (event) { case event_signon: case event_signoff: - case event_away: - case event_back: g_snprintf(buf, sizeof buf, "%lu", (unsigned long)arg1); + break; + case event_away: + g_snprintf(buf, sizeof buf, "%lu %s", (unsigned long)arg1, + ((struct gaim_connection *)arg1)->away ? + ((struct gaim_connection *)arg1)->away : ""); break; case event_im_recv: g_snprintf(buf, sizeof buf, "%lu \"%s\" %s", (unsigned long)arg1, |
From: Eric W. <war...@us...> - 2001-10-03 20:36:36
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv9636 Modified Files: buddy_chat.c conversation.c Log Message: stuff Index: buddy_chat.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/buddy_chat.c,v retrieving revision 1.122 retrieving revision 1.123 diff -u -d -r1.122 -r1.123 --- buddy_chat.c 2001/09/29 01:36:02 1.122 +++ buddy_chat.c 2001/10/03 20:36:33 1.123 @@ -1384,6 +1384,9 @@ GTK_SIGNAL_FUNC(invite_callback), c); gtk_signal_connect(GTK_OBJECT(c->whisper), "clicked", GTK_SIGNAL_FUNC(whisper_callback), c); + + update_buttons_by_protocol(c); + bcs = bcs->next; } C = C->next; Index: conversation.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/conversation.c,v retrieving revision 1.270 retrieving revision 1.271 diff -u -d -r1.270 -r1.271 --- conversation.c 2001/09/28 23:35:44 1.270 +++ conversation.c 2001/10/03 20:36:33 1.271 @@ -760,7 +760,7 @@ gtk_signal_emit_stop_by_name(GTK_OBJECT(entry), "key_press_event"); } else if (((!c->is_chat && (im_options & OPT_IM_ONE_WINDOW)) || (c->is_chat && (chat_options & OPT_CHAT_ONE_WINDOW))) && - (event->state & GDK_MOD1_MASK) && isdigit(event->keyval) && (event->keyval > '0')) { + (event->state & GDK_MOD1_MASK) && (event->keyval > '0') && (event->keyval <= '9')) { GtkWidget *notebook = (c->is_chat ? chat_notebook : convo_notebook); gtk_notebook_set_page(GTK_NOTEBOOK(notebook), event->keyval - '1'); gtk_signal_emit_stop_by_name(GTK_OBJECT(entry), "key_press_event"); |
Update of /cvsroot/gaim/gaim/src/protocols/oscar In directory usw-pr-cvs1:/tmp/cvs-serv9636/protocols/oscar Modified Files: aim.h aim_internal.h buddylist.c chat.c ft.c im.c info.c login.c oscar.c tlv.c Log Message: stuff Index: aim.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/aim.h,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- aim.h 2001/09/20 03:16:43 1.8 +++ aim.h 2001/10/03 20:36:33 1.9 @@ -375,21 +375,31 @@ /* * AIM User Info, Standard Form. */ -struct aim_userinfo_s { +typedef struct { char sn[MAXSNLEN+1]; fu16_t warnlevel; fu16_t idletime; fu16_t flags; fu32_t membersince; fu32_t onlinesince; - fu32_t sessionlen; + fu32_t sessionlen; + int capspresent; fu16_t capabilities; struct { fu16_t status; fu32_t ipaddr; fu8_t crap[0x25]; /* until we figure it out... */ } icqinfo; -}; +} aim_userinfo_t; + +faim_export const char *aim_userinfo_sn(aim_userinfo_t *ui); +faim_export fu16_t aim_userinfo_flags(aim_userinfo_t *ui); +faim_export fu16_t aim_userinfo_idle(aim_userinfo_t *ui); +faim_export float aim_userinfo_warnlevel(aim_userinfo_t *ui); +faim_export time_t aim_userinfo_membersince(aim_userinfo_t *ui); +faim_export time_t aim_userinfo_onlinesince(aim_userinfo_t *ui); +faim_export fu32_t aim_userinfo_sessionlen(aim_userinfo_t *ui); +faim_export int aim_userinfo_hascap(aim_userinfo_t *ui, fu16_t cap); #define AIM_FLAG_UNCONFIRMED 0x0001 /* "damned transients" */ #define AIM_FLAG_ADMINISTRATOR 0x0002 @@ -449,7 +459,7 @@ faim_internal int aim_addtlvtochain_raw(aim_tlvlist_t **list, const fu16_t t, const fu16_t l, const fu8_t *v); faim_internal int aim_addtlvtochain_caps(aim_tlvlist_t **list, const fu16_t t, const fu16_t caps); faim_internal int aim_addtlvtochain_noval(aim_tlvlist_t **list, const fu16_t type); -faim_internal int aim_addtlvtochain_userinfo(aim_tlvlist_t **list, fu16_t type, struct aim_userinfo_s *ui); +faim_internal int aim_addtlvtochain_userinfo(aim_tlvlist_t **list, fu16_t type, aim_userinfo_t *ui); faim_internal int aim_addtlvtochain_frozentlvlist(aim_tlvlist_t **list, fu16_t type, aim_tlvlist_t **tl); faim_internal int aim_counttlvchain(aim_tlvlist_t **list); faim_internal int aim_sizetlvchain(aim_tlvlist_t **list); @@ -835,7 +845,7 @@ faim_export aim_conn_t *aim_accepttransfer(aim_session_t *sess, aim_conn_t *conn, const char *sn, const fu8_t *cookie, const fu8_t *ip, fu16_t listingfiles, fu16_t listingtotsize, fu16_t listingsize, fu32_t listingchecksum, fu16_t rendid); faim_export int aim_getinfo(aim_session_t *, aim_conn_t *, const char *, unsigned short); -faim_export int aim_sendbuddyoncoming(aim_session_t *sess, aim_conn_t *conn, struct aim_userinfo_s *info); +faim_export int aim_sendbuddyoncoming(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *info); faim_export int aim_sendbuddyoffgoing(aim_session_t *sess, aim_conn_t *conn, const char *sn); #define AIM_IMPARAM_FLAG_CHANMSGS_ALLOWED 0x00000001 Index: aim_internal.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/aim_internal.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- aim_internal.h 2001/09/12 00:39:51 1.3 +++ aim_internal.h 2001/10/03 20:36:33 1.4 @@ -160,8 +160,8 @@ faim_internal int aim_msgcookie_gettype(int reqclass); faim_internal int aim_cookie_free(aim_session_t *sess, aim_msgcookie_t *cookie); -faim_internal int aim_extractuserinfo(aim_session_t *sess, aim_bstream_t *bs, struct aim_userinfo_s *); -faim_internal int aim_putuserinfo(aim_bstream_t *bs, struct aim_userinfo_s *info); +faim_internal int aim_extractuserinfo(aim_session_t *sess, aim_bstream_t *bs, aim_userinfo_t *); +faim_internal int aim_putuserinfo(aim_bstream_t *bs, aim_userinfo_t *info); faim_internal int aim_chat_readroominfo(aim_bstream_t *bs, struct aim_chat_roominfo *outinfo); Index: buddylist.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/buddylist.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- buddylist.c 2001/09/20 03:16:43 1.3 +++ buddylist.c 2001/10/03 20:36:33 1.4 @@ -13,7 +13,7 @@ */ static int buddychange(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs) { - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; aim_rxcallback_t userfunc; aim_extractuserinfo(sess, bs, &userinfo); Index: chat.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/chat.c,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- chat.c 2001/09/12 00:39:51 1.4 +++ chat.c 2001/10/03 20:36:33 1.5 @@ -389,7 +389,7 @@ */ static int infoupdate(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs) { - struct aim_userinfo_s *userinfo = NULL; + aim_userinfo_t *userinfo = NULL; aim_rxcallback_t userfunc; int ret = 0; int usercount = 0; @@ -443,7 +443,7 @@ tmptlv = aim_gettlv(tlvlist, 0x0073, 1); /* Allocate enough userinfo structs for all occupants */ - userinfo = calloc(usercount, sizeof(struct aim_userinfo_s)); + userinfo = calloc(usercount, sizeof(aim_userinfo_t)); aim_bstream_init(&occbs, tmptlv->value, tmptlv->length); @@ -551,13 +551,13 @@ static int userlistchange(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs) { - struct aim_userinfo_s *userinfo = NULL; + aim_userinfo_t *userinfo = NULL; aim_rxcallback_t userfunc; int curcount = 0, ret = 0; while (aim_bstream_empty(bs)) { curcount++; - userinfo = realloc(userinfo, curcount * sizeof(struct aim_userinfo_s)); + userinfo = realloc(userinfo, curcount * sizeof(aim_userinfo_t)); aim_extractuserinfo(sess, bs, &userinfo[curcount-1]); } @@ -594,7 +594,7 @@ */ static int incomingmsg(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs) { - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; aim_rxcallback_t userfunc; int ret = 0; fu8_t *cookie; @@ -603,7 +603,7 @@ char *msg = NULL; aim_msgcookie_t *ck; - memset(&userinfo, 0, sizeof(struct aim_userinfo_s)); + memset(&userinfo, 0, sizeof(aim_userinfo_t)); /* * ICBM Cookie. Uncache it. Index: ft.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/ft.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- ft.c 2001/09/09 10:12:26 1.3 +++ ft.c 2001/10/03 20:36:33 1.4 @@ -825,7 +825,7 @@ return -1; } - if (setsockopt(listenfd, SOL_SOCKET, SO_REUSEADDR, (char *)&on, sizeof(on) != 0)) { + if (setsockopt(listenfd, SOL_SOCKET, SO_REUSEADDR, (char *)&on, sizeof(on)) != 0) { perror("setsockopt(listenfd)"); close(listenfd); return -1; Index: im.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/im.c,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- im.c 2001/09/21 20:47:37 1.8 +++ im.c 2001/10/03 20:36:33 1.9 @@ -794,7 +794,7 @@ * 0101 000b 0000 0000 3c2f 4854 4d4c 3e another ASCII part * */ -static int incomingim_ch1(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, fu16_t channel, struct aim_userinfo_s *userinfo, aim_bstream_t *bs, fu8_t *cookie) +static int incomingim_ch1(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, fu16_t channel, aim_userinfo_t *userinfo, aim_bstream_t *bs, fu8_t *cookie) { fu16_t type, length; aim_rxcallback_t userfunc; @@ -893,7 +893,7 @@ return ret; } -static int incomingim_ch2_buddylist(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_buddylist(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { aim_rxcallback_t userfunc; int ret = 0; @@ -955,7 +955,7 @@ return ret; } -static int incomingim_ch2_buddyicon(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_buddyicon(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { aim_rxcallback_t userfunc; int ret = 0; @@ -979,7 +979,7 @@ return ret; } -static int incomingim_ch2_voice(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_voice(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { aim_msgcookie_t *cachedcook; int ret = 0; @@ -1005,7 +1005,7 @@ return ret; } -static int incomingim_ch2_chat(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_chat(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { aim_tlv_t *miscinfo; aim_bstream_t tbs; @@ -1038,7 +1038,7 @@ return ret; } -static int incomingim_ch2_getfile(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_getfile(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { char ip[30]; aim_msgcookie_t *cachedcook; @@ -1083,7 +1083,7 @@ return ret; } -static int incomingim_ch2_sendfile(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_sendfile(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { #if 0 char ip[30]; @@ -1145,7 +1145,7 @@ return 0; } -static int incomingim_ch2_imimage(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) +static int incomingim_ch2_imimage(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args, aim_tlvlist_t *list2) { aim_rxcallback_t userfunc; int ret = 0; @@ -1204,7 +1204,7 @@ } /* XXX Ugh. I think its obvious. */ -static int incomingim_ch2(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, fu16_t channel, struct aim_userinfo_s *userinfo, aim_tlvlist_t *tlvlist, fu8_t *cookie) +static int incomingim_ch2(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, fu16_t channel, aim_userinfo_t *userinfo, aim_tlvlist_t *tlvlist, fu8_t *cookie) { aim_tlv_t *block1; aim_tlvlist_t *list2; @@ -1357,9 +1357,9 @@ int i, ret = 0; fu8_t cookie[8]; fu16_t channel; - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; - memset(&userinfo, 0x00, sizeof(struct aim_userinfo_s)); + memset(&userinfo, 0x00, sizeof(aim_userinfo_t)); /* * Read ICBM Cookie. And throw away. @@ -1542,7 +1542,7 @@ int ret = 0; aim_rxcallback_t userfunc; fu16_t channel, nummissed, reason; - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; while (aim_bstream_empty(bs)) { Index: info.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/info.c,v retrieving revision 1.4 retrieving revision 1.5 diff -u -d -r1.4 -r1.5 --- info.c 2001/09/20 03:16:43 1.4 +++ info.c 2001/10/03 20:36:33 1.5 @@ -43,6 +43,79 @@ return 0; } +faim_export const char *aim_userinfo_sn(aim_userinfo_t *ui) +{ + + if (!ui) + return NULL; + + return ui->sn; +} + +faim_export fu16_t aim_userinfo_flags(aim_userinfo_t *ui) +{ + + if (!ui) + return 0; + + return ui->flags; +} + +faim_export fu16_t aim_userinfo_idle(aim_userinfo_t *ui) +{ + + if (!ui) + return 0; + + return ui->idletime; +} + +faim_export float aim_userinfo_warnlevel(aim_userinfo_t *ui) +{ + + if (!ui) + return 0.00; + + return (ui->warnlevel / 10); +} + +faim_export time_t aim_userinfo_membersince(aim_userinfo_t *ui) +{ + + if (!ui) + return 0; + + return (time_t)ui->membersince; +} + +faim_export time_t aim_userinfo_onlinesince(aim_userinfo_t *ui) +{ + + if (!ui) + return 0; + + return (time_t)ui->onlinesince; +} + +faim_export fu32_t aim_userinfo_sessionlen(aim_userinfo_t *ui) +{ + + if (!ui) + return 0; + + return ui->sessionlen; +} + +faim_export int aim_userinfo_hascap(aim_userinfo_t *ui, fu16_t cap) +{ + + if (!ui || !ui->capspresent) + return -1; + + return !!(ui->capabilities & cap); +} + + /* * Capability blocks. */ @@ -158,7 +231,7 @@ * AIM is fairly regular about providing user info. This is a generic * routine to extract it in its standard form. */ -faim_internal int aim_extractuserinfo(aim_session_t *sess, aim_bstream_t *bs, struct aim_userinfo_s *outinfo) +faim_internal int aim_extractuserinfo(aim_session_t *sess, aim_bstream_t *bs, aim_userinfo_t *outinfo) { int curtlv, tlvcnt; fu8_t snlen; @@ -167,7 +240,7 @@ return -EINVAL; /* Clear out old data first */ - memset(outinfo, 0x00, sizeof(struct aim_userinfo_s)); + memset(outinfo, 0x00, sizeof(aim_userinfo_t)); /* * Screen name. Stored as an unterminated string prepended with a @@ -283,6 +356,7 @@ * */ outinfo->capabilities = aim_getcap(sess, bs, length); + outinfo->capspresent = 1; } else if (type == 0x000e) { /* @@ -337,7 +411,7 @@ /* * Inverse of aim_extractuserinfo() */ -faim_internal int aim_putuserinfo(aim_bstream_t *bs, struct aim_userinfo_s *info) +faim_internal int aim_putuserinfo(aim_bstream_t *bs, aim_userinfo_t *info) { aim_tlvlist_t *tlvlist = NULL; @@ -373,7 +447,7 @@ return 0; } -faim_export int aim_sendbuddyoncoming(aim_session_t *sess, aim_conn_t *conn, struct aim_userinfo_s *info) +faim_export int aim_sendbuddyoncoming(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *info) { aim_frame_t *fr; aim_snacid_t snacid; @@ -469,7 +543,7 @@ static int userinfo(aim_session_t *sess, aim_module_t *mod, aim_frame_t *rx, aim_modsnac_t *snac, aim_bstream_t *bs) { - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; char *text_encoding = NULL, *text = NULL; aim_rxcallback_t userfunc; aim_tlvlist_t *tlvlist; Index: login.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/login.c,v retrieving revision 1.6 retrieving revision 1.7 diff -u -d -r1.6 -r1.7 --- login.c 2001/09/21 20:47:37 1.6 +++ login.c 2001/10/03 20:36:33 1.7 @@ -617,9 +617,9 @@ { aim_rxcallback_t userfunc; fu16_t newevil; - struct aim_userinfo_s userinfo; + aim_userinfo_t userinfo; - memset(&userinfo, 0, sizeof(struct aim_userinfo_s)); + memset(&userinfo, 0, sizeof(aim_userinfo_t)); newevil = aimbs_get16(bs); Index: oscar.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/oscar.c,v retrieving revision 1.42 retrieving revision 1.43 diff -u -d -r1.42 -r1.43 --- oscar.c 2001/10/02 05:52:56 1.42 +++ oscar.c 2001/10/03 20:36:33 1.43 @@ -1121,7 +1121,7 @@ } static int gaim_parse_oncoming(aim_session_t *sess, aim_frame_t *fr, ...) { - struct aim_userinfo_s *info; + aim_userinfo_t *info; time_t time_idle; int type = 0; struct gaim_connection *gc = sess->aux_data; @@ -1129,7 +1129,7 @@ va_list ap; va_start(ap, fr); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); va_end(ap); if (info->flags & AIM_FLAG_ACTIVEBUDDY) @@ -1163,12 +1163,12 @@ } static int gaim_parse_offgoing(aim_session_t *sess, aim_frame_t *fr, ...) { - struct aim_userinfo_s *info; + aim_userinfo_t *info; va_list ap; struct gaim_connection *gc = sess->aux_data; va_start(ap, fr); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); va_end(ap); serv_got_update(gc, info->sn, 0, 0, 0, 0, 0, 0); @@ -1267,7 +1267,7 @@ return TRUE; } -static int incomingim_chan1(aim_session_t *sess, aim_conn_t *conn, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch1_args *args) { +static int incomingim_chan1(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch1_args *args) { char *tmp = g_malloc(BUF_LONG); struct gaim_connection *gc = sess->aux_data; int flags = 0; @@ -1351,7 +1351,7 @@ return 1; } -static int incomingim_chan2(aim_session_t *sess, aim_conn_t *conn, struct aim_userinfo_s *userinfo, struct aim_incomingim_ch2_args *args) { +static int incomingim_chan2(aim_session_t *sess, aim_conn_t *conn, aim_userinfo_t *userinfo, struct aim_incomingim_ch2_args *args) { struct gaim_connection *gc = sess->aux_data; if (args->reqclass & AIM_CAPS_CHAT) { @@ -1398,12 +1398,12 @@ static int gaim_parse_incoming_im(aim_session_t *sess, aim_frame_t *fr, ...) { int channel, ret = 0; - struct aim_userinfo_s *userinfo; + aim_userinfo_t *userinfo; va_list ap; va_start(ap, fr); channel = va_arg(ap, int); - userinfo = va_arg(ap, struct aim_userinfo_s *); + userinfo = va_arg(ap, aim_userinfo_t *); /* channel 1: standard message */ if (channel == 1) { @@ -1429,12 +1429,12 @@ static int gaim_parse_misses(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; fu16_t chan, nummissed, reason; - struct aim_userinfo_s *userinfo; + aim_userinfo_t *userinfo; char buf[1024]; va_start(ap, fr); chan = (fu16_t)va_arg(ap, unsigned int); - userinfo = va_arg(ap, struct aim_userinfo_s *); + userinfo = va_arg(ap, aim_userinfo_t *); nummissed = (fu16_t)va_arg(ap, unsigned int); reason = (fu16_t)va_arg(ap, unsigned int); va_end(ap); @@ -1562,7 +1562,7 @@ } static int gaim_parse_user_info(aim_session_t *sess, aim_frame_t *fr, ...) { - struct aim_userinfo_s *info; + aim_userinfo_t *info; char *prof_enc = NULL, *prof = NULL; fu16_t infotype; char buf[BUF_LONG]; @@ -1572,7 +1572,7 @@ char *asc; va_start(ap, fr); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); prof_enc = va_arg(ap, char *); prof = va_arg(ap, char *); infotype = (fu16_t)va_arg(ap, unsigned int); @@ -1712,14 +1712,14 @@ static int gaim_chat_join(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; int count, i; - struct aim_userinfo_s *info; + aim_userinfo_t *info; struct gaim_connection *g = sess->aux_data; struct chat_connection *c = NULL; va_start(ap, fr); count = va_arg(ap, int); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); va_end(ap); c = find_oscar_chat_by_conn(g, fr->conn); @@ -1735,14 +1735,14 @@ static int gaim_chat_leave(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; int count, i; - struct aim_userinfo_s *info; + aim_userinfo_t *info; struct gaim_connection *g = sess->aux_data; struct chat_connection *c = NULL; va_start(ap, fr); count = va_arg(ap, int); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); va_end(ap); c = find_oscar_chat_by_conn(g, fr->conn); @@ -1757,7 +1757,7 @@ static int gaim_chat_info_update(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; - struct aim_userinfo_s *userinfo; + aim_userinfo_t *userinfo; struct aim_chat_roominfo *roominfo; char *roomname; int usercount; @@ -1771,7 +1771,7 @@ roominfo = va_arg(ap, struct aim_chat_roominfo *); roomname = va_arg(ap, char *); usercount= va_arg(ap, int); - userinfo = va_arg(ap, struct aim_userinfo_s *); + userinfo = va_arg(ap, aim_userinfo_t *); roomdesc = va_arg(ap, char *); unknown_c9 = (fu16_t)va_arg(ap, int); creationtime = (fu32_t)va_arg(ap, unsigned long); @@ -1792,14 +1792,14 @@ static int gaim_chat_incoming_msg(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; - struct aim_userinfo_s *info; + aim_userinfo_t *info; char *msg; struct gaim_connection *gc = sess->aux_data; struct chat_connection *ccon = find_oscar_chat_by_conn(gc, fr->conn); char *tmp; va_start(ap, fr); - info = va_arg(ap, struct aim_userinfo_s *); + info = va_arg(ap, aim_userinfo_t *); msg = va_arg(ap, char *); tmp = g_malloc(BUF_LONG); @@ -1879,12 +1879,12 @@ static int gaim_parse_evilnotify(aim_session_t *sess, aim_frame_t *fr, ...) { va_list ap; fu16_t newevil; - struct aim_userinfo_s *userinfo; + aim_userinfo_t *userinfo; struct gaim_connection *gc = sess->aux_data; va_start(ap, fr); newevil = (fu16_t)va_arg(ap, unsigned int); - userinfo = va_arg(ap, struct aim_userinfo_s *); + userinfo = va_arg(ap, aim_userinfo_t *); va_end(ap); serv_got_eviled(gc, (userinfo && userinfo->sn[0]) ? userinfo->sn : NULL, newevil / 10); Index: tlv.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/oscar/tlv.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- tlv.c 2001/09/12 00:39:51 1.3 +++ tlv.c 2001/10/03 20:36:33 1.4 @@ -266,6 +266,9 @@ fu8_t buf[16*16]; /* icky fixed length buffer */ aim_bstream_t bs; + if (!caps) + return 0; /* nothing there anyway */ + aim_bstream_init(&bs, buf, sizeof(buf)); aim_putcap(&bs, caps); @@ -273,7 +276,7 @@ return aim_addtlvtochain_raw(list, t, aim_bstream_curpos(&bs), buf); } -faim_internal int aim_addtlvtochain_userinfo(aim_tlvlist_t **list, fu16_t type, struct aim_userinfo_s *ui) +faim_internal int aim_addtlvtochain_userinfo(aim_tlvlist_t **list, fu16_t type, aim_userinfo_t *ui) { fu8_t buf[1024]; /* bleh */ aim_bstream_t bs; |
From: Eric W. <war...@us...> - 2001-10-03 19:42:34
|
Update of /cvsroot/gaim/gaim/po In directory usw-pr-cvs1:/tmp/cvs-serv7090 Modified Files: pl.po Log Message: Arkadiusz Miskiewicz's updated translation Index: pl.po =================================================================== RCS file: /cvsroot/gaim/gaim/po/pl.po,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- pl.po 2001/10/01 22:54:05 1.3 +++ pl.po 2001/10/03 19:42:31 1.4 @@ -1,18 +1,198 @@ # GAIM polish translation . -# Copyright (C) YEAR Free Software Foundation, Inc. +# Copyright (C) 2001 Free Software Foundation, Inc. # Przemys³aw Su³ek <pb...@li...> <ps...@pl...>, 2001. # msgid "" msgstr "" -"Project-Id-Version: PACKAGE VERSION\n" -"POT-Creation-Date: 2001-09-29 00:00-0700\n" +"Project-Id-Version: gaim 0.45\n" +"POT-Creation-Date: 2001-10-03 14:19+0200\n" [...1381 lines suppressed...] -#: src/prpl.c:131 +#: src/prpl.c:132 msgid "Accept?" msgstr "Akcpetujesz?" -#: src/prpl.c:152 src/prpl.c:224 +#: src/prpl.c:153 src/prpl.c:225 msgid "Accept" msgstr "Akceptuj" -#: src/prpl.c:197 +#: src/prpl.c:198 msgid "Gaim - Prompt" msgstr "Gaim - prompt" @@ -2424,3 +2575,4 @@ #: src/server.c:810 msgid "No" msgstr "Nie" + |
Update of /cvsroot/gaim/gaim/src/protocols/zephyr In directory usw-pr-cvs1:/tmp/cvs-serv4894 Modified Files: .cvsignore Makefile.am ZInit.c ZLocations.c ZSendPkt.c ZSubs.c Zinternal.c internal.h zephyr.h Added Files: ZhmStat.c Log Message: Salvatore Valente says this is better. --- NEW FILE: ZhmStat.c --- /* This file is part of the Project Athena Zephyr Notification System. * It contains the ZhmStat() function. * * Created by: Marc Horowitz * * $Id: ZhmStat.c,v 1.1 2001/10/03 19:38:28 warmenhoven Exp $ * * Copyright (c) 1996 by the Massachusetts Institute of Technology. * For copying and distribution information, see the file * "mit-copyright.h". */ #include <internal.h> #include <sys/socket.h> #ifndef INADDR_LOOPBACK #define INADDR_LOOPBACK 0x7f000001 #endif Code_t ZhmStat(hostaddr, notice) struct in_addr *hostaddr; ZNotice_t *notice; { struct servent *sp; struct sockaddr_in sin; ZNotice_t req; Code_t code; struct timeval tv; fd_set readers; (void) memset((char *)&sin, 0, sizeof(struct sockaddr_in)); sp = getservbyname(HM_SVCNAME, "udp"); sin.sin_port = (sp) ? sp->s_port : HM_SVC_FALLBACK; sin.sin_family = AF_INET; if (hostaddr) sin.sin_addr = *hostaddr; else sin.sin_addr.s_addr = htonl(INADDR_LOOPBACK); (void) memset((char *)&req, 0, sizeof(req)); req.z_kind = STAT; req.z_port = 0; req.z_class = HM_STAT_CLASS; req.z_class_inst = HM_STAT_CLIENT; req.z_opcode = HM_GIMMESTATS; req.z_sender = ""; req.z_recipient = ""; req.z_default_format = ""; req.z_message_len = 0; if ((code = ZSetDestAddr(&sin)) != ZERR_NONE) return(code); if ((code = ZSendNotice(&req, ZNOAUTH)) != ZERR_NONE) return(code); /* Wait up to ten seconds for a response. */ FD_ZERO(&readers); FD_SET(ZGetFD(), &readers); tv.tv_sec = 10; tv.tv_usec = 0; code = select(ZGetFD() + 1, &readers, NULL, NULL, &tv); if (code < 0 && errno != EINTR) return(errno); if (code == 0 || (code < 0 && errno == EINTR) || ZPending() == 0) return(ZERR_HMDEAD); return(ZReceiveNotice(notice, (struct sockaddr_in *) 0)); } Index: .cvsignore =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/.cvsignore,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- .cvsignore 2001/07/31 01:00:38 1.1 +++ .cvsignore 2001/10/03 19:38:28 1.2 @@ -49,6 +49,7 @@ ZSubs.lo ZVariables.lo ZWait4Not.lo +ZhmStat.lo Zinternal.lo error_message.lo et_name.lo Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/Makefile.am,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Makefile.am 2001/09/21 20:47:37 1.2 +++ Makefile.am 2001/10/03 19:38:28 1.3 @@ -129,6 +129,7 @@ ZSubs.c \ ZVariables.c \ ZWait4Not.c \ + ZhmStat.c \ Zinternal.c \ com_err.h \ error_message.c \ Index: ZInit.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/ZInit.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ZInit.c 2001/07/31 01:00:39 1.1 +++ ZInit.c 2001/10/03 19:38:28 1.2 @@ -24,12 +24,24 @@ #include <krb_err.h> #endif +#ifndef INADDR_NONE +#define INADDR_NONE 0xffffffff +#endif + Code_t ZInitialize() { struct servent *hmserv; - char addr[4]; + struct hostent *hostent; + char addr[4], hostname[MAXHOSTNAMELEN]; + struct in_addr servaddr; + struct sockaddr_in sin; + int s, sinsize = sizeof(sin); + Code_t code; + ZNotice_t notice; #ifdef ZEPHYR_USES_KERBEROS + char *krealm = NULL; int krbval; + char d1[ANAME_SZ], d2[INST_SZ]; initialize_krb_error_table(); #endif @@ -53,17 +65,88 @@ __HM_set = 0; + /* Initialize the input queue */ + __Q_Tail = NULL; + __Q_Head = NULL; + + /* if the application is a server, there might not be a zhm. The + code will fall back to something which might not be "right", + but this is is ok, since none of the servers call krb_rd_req. */ + + servaddr.s_addr = INADDR_NONE; + if (! __Zephyr_server) { + if ((code = ZOpenPort(NULL)) != ZERR_NONE) + return(code); + + if ((code = ZhmStat(NULL, ¬ice)) != ZERR_NONE) + return(code); + + ZClosePort(); + + /* the first field, which is NUL-terminated, is the server name. + If this code ever support a multiplexing zhm, this will have to + be made smarter, and probably per-message */ + #ifdef ZEPHYR_USES_KERBEROS - if ((krbval = krb_get_lrealm(__Zephyr_realm, 1)) != KSUCCESS) + krealm = krb_realmofhost(notice.z_message); +#endif + hostent = gethostbyname(notice.z_message); + if (hostent && hostent->h_addrtype == AF_INET) + memcpy(&servaddr, hostent->h_addr, sizeof(servaddr)); + + ZFreeNotice(¬ice); + } + +#ifdef ZEPHYR_USES_KERBEROS + if (krealm) { + strcpy(__Zephyr_realm, krealm); + } else if ((krb_get_tf_fullname(TKT_FILE, d1, d2, __Zephyr_realm) + != KSUCCESS) && + ((krbval = krb_get_lrealm(__Zephyr_realm, 1)) != KSUCCESS)) { return (krbval); + } +#else + strcpy(__Zephyr_realm, "local-realm"); #endif + __My_addr.s_addr = INADDR_NONE; + if (servaddr.s_addr != INADDR_NONE) { + /* Try to get the local interface address by connecting a UDP + * socket to the server address and getting the local address. + * Some broken operating systems (e.g. Solaris 2.0-2.5) yield + * INADDR_ANY (zero), so we have to check for that. */ + s = socket(AF_INET, SOCK_DGRAM, 0); + if (s != -1) { + memset(&sin, 0, sizeof(sin)); + sin.sin_family = AF_INET; + memcpy(&sin.sin_addr, &servaddr, sizeof(servaddr)); + sin.sin_port = HM_SRV_SVC_FALLBACK; + if (connect(s, (struct sockaddr *) &sin, sizeof(sin)) == 0 + && getsockname(s, (struct sockaddr *) &sin, &sinsize) == 0 + && sin.sin_addr.s_addr != 0) + memcpy(&__My_addr, &sin.sin_addr, sizeof(__My_addr)); + close(s); + } + } + if (__My_addr.s_addr == INADDR_NONE) { + /* We couldn't figure out the local interface address by the + * above method. Try by resolving the local hostname. (This + * is a pretty broken thing to do, and unfortunately what we + * always do on server machines.) */ + if (gethostname(hostname, sizeof(hostname)) == 0) { + hostent = gethostbyname(hostname); + if (hostent && hostent->h_addrtype == AF_INET) + memcpy(&__My_addr, hostent->h_addr, sizeof(__My_addr)); + } + } + /* If the above methods failed, zero out __My_addr so things will + * sort of kind of work. */ + if (__My_addr.s_addr == INADDR_NONE) + __My_addr.s_addr = 0; + /* Get the sender so we can cache it */ (void) ZGetSender(); - /* Initialize the input queue */ - __Q_Tail = NULL; - __Q_Head = NULL; - return (ZERR_NONE); } + Index: ZLocations.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/ZLocations.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ZLocations.c 2001/07/31 01:00:39 1.1 +++ ZLocations.c 2001/10/03 19:38:28 1.2 @@ -55,7 +55,7 @@ int retval; time_t ourtime; ZNotice_t notice, retnotice; - char *bptr[3]; + char *bptr[3], *p; #ifndef X_DISPLAY_MISSING char *display; #endif @@ -89,36 +89,29 @@ (void) strncpy(host, hent->h_name, sizeof(host)); host[sizeof(host) - 1] = '\0'; } - bptr[0] = host; #ifndef X_DISPLAY_MISSING if ((display = getenv("DISPLAY")) && *display) { (void) strcpy(mytty, display); - bptr[2] = mytty; } else { #endif ttyp = ttyname(0); - if (ttyp) { - bptr[2] = strrchr(ttyp, '/'); - if (bptr[2]) - bptr[2]++; - else - bptr[2] = ttyp; + if (ttyp && *ttyp) { + p = strchr(ttyp + 1, '/'); + strcpy(mytty, (p) ? p + 1 : ttyp); + } else { + strcpy(mytty, "unknown"); } - else - bptr[2] = "unknown"; - (void) strcpy(mytty, bptr[2]); #ifndef X_DISPLAY_MISSING } #endif reenter = 1; - } else { - bptr[0] = host; - bptr[2] = mytty; } ourtime = time((time_t *)0); + bptr[0] = host; bptr[1] = ctime(&ourtime); bptr[1][strlen(bptr[1])-1] = '\0'; + bptr[2] = mytty; if ((retval = ZSendList(¬ice, bptr, 3, auth)) != ZERR_NONE) Index: ZSendPkt.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/ZSendPkt.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ZSendPkt.c 2001/07/31 01:00:39 1.1 +++ ZSendPkt.c 2001/10/03 19:38:28 1.2 @@ -20,7 +20,7 @@ #include <internal.h> #include <sys/socket.h> -static int wait_for_ack(); +static int wait_for_hmack(); Code_t ZSendPacket(packet, len, waitforack) char *packet; @@ -53,7 +53,7 @@ if ((retval = ZParseNotice(packet, len, ¬ice)) != ZERR_NONE) return (retval); - retval = Z_WaitForNotice (&acknotice, wait_for_ack, ¬ice.z_uid, + retval = Z_WaitForNotice (&acknotice, wait_for_hmack, ¬ice.z_uid, HM_TIMEOUT); if (retval == ETIMEDOUT) return ZERR_HMDEAD; @@ -62,12 +62,9 @@ return retval; } -static int wait_for_ack(notice, uid) +static int wait_for_hmack(notice, uid) ZNotice_t *notice; ZUnique_Id_t *uid; { - return (ZCompareUID(¬ice->z_uid, uid) && - (notice->z_kind == HMACK || - notice->z_kind == SERVACK || - notice->z_kind == CLIENTACK )); + return (notice->z_kind == HMACK && ZCompareUID(¬ice->z_uid, uid)); } Index: ZSubs.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/ZSubs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- ZSubs.c 2001/07/31 01:00:39 1.1 +++ ZSubs.c 2001/10/03 19:38:28 1.2 @@ -103,7 +103,7 @@ retval = Z_FormatHeader(¬ice, header, sizeof(header), &hdrlen, ZAUTH); if (retval != ZERR_NONE && !authit) retval = Z_FormatHeader(¬ice, header, sizeof(header), - &hdrlen, ZAUTH); + &hdrlen, ZNOAUTH); if (retval != ZERR_NONE) { free((char *)list); return(retval); Index: Zinternal.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/Zinternal.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- Zinternal.c 2001/07/31 01:00:39 1.1 +++ Zinternal.c 2001/10/03 19:38:28 1.2 @@ -30,8 +30,7 @@ int __Zephyr_fd = -1; int __Zephyr_open; int __Zephyr_port = -1; -int __My_length; -char *__My_addr; +struct in_addr __My_addr; int __Q_CompleteLength; int __Q_Size; struct _Z_InputQ *__Q_Head, *__Q_Tail; @@ -45,11 +44,12 @@ ZSubscription_t *__subscriptions_list; int __subscriptions_num; int __subscriptions_next; +int Z_discarded_packets = 0; #ifdef ZEPHYR_USES_KERBEROS C_Block __Zephyr_session; -char __Zephyr_realm[REALM_SZ]; #endif +char __Zephyr_realm[REALM_SZ]; #ifdef Z_DEBUG void (*__Z_debug_print) __P((const char *fmt, va_list args, void *closure)); @@ -133,35 +133,6 @@ return 0; } -/* Get the address of the local host and cache it */ - -Code_t Z_GetMyAddr() -{ - register struct hostent *myhost; - char hostname[MAXHOSTNAMELEN]; - - if (__My_length > 0) - return (ZERR_NONE); - - if (gethostname(hostname, MAXHOSTNAMELEN) < 0) - return (errno); - - if (!(myhost = gethostbyname(hostname))) - return (errno); - - /* If h_length is 0, that is a serious problem and it doesn't - make it worse for malloc(0) to return NULL, so don't worry - about that case. */ - if (!(__My_addr = (char *)malloc((unsigned)myhost->h_length))) - return (ENOMEM); - - __My_length = myhost->h_length; - - (void) memcpy(__My_addr, myhost->h_addr, myhost->h_length); - - return (ZERR_NONE); -} - /* Return 1 if there is a packet waiting, 0 otherwise */ @@ -254,14 +225,25 @@ ZNotice_t notice; ZPacket_t packet; struct sockaddr_in olddest, from; - int from_len, packet_len, part, partof; + int from_len, packet_len, zvlen, part, partof; char *slash; Code_t retval; - register int i; + fd_set fds; + struct timeval tv; if (ZGetFD() < 0) return (ZERR_NOPORT); + FD_ZERO(&fds); + FD_SET(ZGetFD(), &fds); + tv.tv_sec = 60; + tv.tv_usec = 0; + + if (select(ZGetFD() + 1, &fds, NULL, NULL, &tv) < 0) + return (errno); + if (!FD_ISSET(ZGetFD(), &fds)) + return ETIMEDOUT; + from_len = sizeof(struct sockaddr_in); packet_len = recvfrom(ZGetFD(), packet, sizeof(packet), 0, @@ -273,15 +255,12 @@ if (!packet_len) return (ZERR_EOF); - /* XXX Check for null data (debugging) */ - for (i = packet_len - 1; i >= 0; i--) - if (packet[i]) - goto not_all_null; -#ifdef Z_DEBUG - Z_debug ("got null packet from %s", inet_ntoa (from.sin_addr)); -#endif - return ZERR_NONE; - not_all_null: + /* Ignore obviously non-Zephyr packets. */ + zvlen = sizeof(ZVERSIONHDR) - 1; + if (packet_len < zvlen || memcmp(packet, ZVERSIONHDR, zvlen) != 0) { + Z_discarded_packets++; + return (ZERR_NONE); + } /* Parse the notice */ if ((retval = ZParseNotice(packet, packet_len, ¬ice)) != ZERR_NONE) @@ -631,10 +610,7 @@ notice->z_uid.tv.tv_sec = htonl((u_long) notice->z_uid.tv.tv_sec); notice->z_uid.tv.tv_usec = htonl((u_long) notice->z_uid.tv.tv_usec); - if ((retval = Z_GetMyAddr()) != ZERR_NONE) - return (retval); - - (void) memcpy((char *)¬ice->z_uid.zuid_addr, __My_addr, __My_length); + (void) memcpy(¬ice->z_uid.zuid_addr, &__My_addr, sizeof(__My_addr)); notice->z_multiuid = notice->z_uid; @@ -742,8 +718,8 @@ } else { if (strlen(notice->z_recipient) + strlen(__Zephyr_realm) + 2 > - sizeof(newrecip)) - return (ZERR_HEADERLEN); + sizeof(newrecip)) + return (ZERR_HEADERLEN); (void) sprintf(newrecip, "%s@%s", notice->z_recipient, __Zephyr_realm); if (Z_AddField(&ptr, newrecip, end)) return (ZERR_HEADERLEN); @@ -905,10 +881,8 @@ htonl((u_long) partnotice.z_uid.tv.tv_sec); partnotice.z_uid.tv.tv_usec = htonl((u_long) partnotice.z_uid.tv.tv_usec); - if ((retval = Z_GetMyAddr()) != ZERR_NONE) - return (retval); - (void) memcpy((char *)&partnotice.z_uid.zuid_addr, __My_addr, - __My_length); + (void) memcpy((char *)&partnotice.z_uid.zuid_addr, &__My_addr, + sizeof(__My_addr)); } message_len = min(notice->z_message_len-offset, fragsize); partnotice.z_message = notice->z_message+offset; Index: internal.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/internal.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- internal.h 2001/07/31 01:00:39 1.1 +++ internal.h 2001/10/03 19:38:28 1.2 @@ -69,6 +69,7 @@ extern int __subscriptions_next; extern int __Zephyr_port; /* Port number */ +extern struct in_addr __My_addr; typedef Code_t (*Z_SendProc) __P((ZNotice_t *, char *, int, int)); Index: zephyr.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/zephyr.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- zephyr.h 2001/07/31 01:00:39 1.1 +++ zephyr.h 2001/10/03 19:38:28 1.2 @@ -21,9 +21,6 @@ #include <sys/time.h> #include <zephyr/zephyr_err.h> -#ifdef ZEPHYR_USES_KERBEROS -#include <krb.h> -#endif #ifndef IPPROTO_MAX /* Make sure not already included */ #include <netinet/in.h> @@ -166,6 +163,7 @@ Code_t ZLocateUser ZP((char *, int *, Z_AuthProc)); Code_t ZRequestLocations ZP((char *, ZAsyncLocateData_t *, ZNotice_Kind_t, Z_AuthProc)); +Code_t ZhmStat ZP((struct in_addr *, ZNotice_t *)); Code_t ZInitialize ZP((void)); Code_t ZSetServerState ZP((int)); Code_t ZSetFD ZP((int)); @@ -178,10 +176,9 @@ Code_t ZMakeAscii16 ZP((char *, int, unsigned int)); Code_t ZReceivePacket ZP((ZPacket_t, int*, struct sockaddr_in*)); Code_t ZCheckAuthentication ZP((ZNotice_t*, struct sockaddr_in*)); +Code_t ZSetLocation ZP((char *exposure)); +Code_t ZUnsetLocation ZP((void)); Code_t ZFlushMyLocations ZP((void)); -#ifdef ZEPHYR_USES_KERBEROS -Code_t ZFormatAuthenticNotice ZP((ZNotice_t*, char*, int, int*, C_Block)); -#endif Code_t ZFormatRawNotice ZP((ZNotice_t *, char**, int *)); Code_t ZRetrieveSubscriptions ZP((unsigned short, int*)); Code_t ZOpenPort ZP((unsigned short *port)); @@ -230,15 +227,6 @@ #define ZGetDestAddr() __HM_addr #define ZGetRealm() __Zephyr_realm -#ifdef ZEPHYR_USES_KERBEROS -/* Session key for last parsed packet - server only */ -extern C_Block __Zephyr_session; -#define ZGetSession() (__Zephyr_session) -#else -#define __Zephyr_realm ("local-realm") -#endif - - #ifdef Z_DEBUG void ZSetDebug ZP((void (*)(ZCONST char *, va_list, void *), void *)); #define ZSetDebug(proc,closure) (__Z_debug_print=(proc), \ @@ -338,5 +326,6 @@ #define USER_REREAD "REREAD" /* Opcode: Reread desc file */ #define USER_SHUTDOWN "SHUTDOWN" /* Opcode: Go catatonic */ #define USER_STARTUP "STARTUP" /* Opcode: Come out of it */ +#define USER_EXIT "EXIT" /* Opcode: Exit the client */ #endif /* __ZEPHYR_H__ */ |
From: Eric W. <war...@us...> - 2001-10-03 18:13:53
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv22742 Modified Files: core.c Log Message: fix -Wall Index: core.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/core.c,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- core.c 2001/10/03 07:49:38 1.1 +++ core.c 2001/10/03 18:13:50 1.2 @@ -37,6 +37,8 @@ #include "gaim.h" +#if DEVEL + static gint UI_fd = -1; struct UI { GIOChannel *channel; @@ -170,6 +172,8 @@ g_log(NULL, G_LOG_LEVEL_CRITICAL, "Unable to open socket: %s", strerror(errno)); return fd; } + +#endif /* DEVEL */ int core_main() { |
From: Eric W. <war...@us...> - 2001-10-03 09:48:36
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv25541/src Modified Files: applet.h convo.h gaim.h html.c multi.h proxy.h prpl.c prpl.h Added Files: core.h ui.h Log Message: boo-yah! --- NEW FILE: core.h --- /* * gaim * * Copyright (C) 1998-1999, Mark Spencer <mar...@ma...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #ifndef _CORE_H_ #define _CORE_H_ #ifdef HAVE_CONFIG_H #include <config.h> #endif #include <stdio.h> #include <time.h> #include <glib.h> #ifdef GAIM_PLUGINS #include <gmodule.h> #endif #include "multi.h" enum gaim_event { event_signon = 0, event_signoff, event_away, event_back, event_im_recv, event_im_send, event_buddy_signon, event_buddy_signoff, event_buddy_away, event_buddy_back, event_buddy_idle, event_buddy_unidle, event_blist_update, event_chat_invited, event_chat_join, event_chat_leave, event_chat_buddy_join, event_chat_buddy_leave, event_chat_recv, event_chat_send, event_warned, event_error, event_quit, event_new_conversation, event_set_info, event_draw_menu, event_im_displayed_sent, event_im_displayed_rcvd, event_chat_send_invite, /* any others? it's easy to add... */ }; #ifdef GAIM_PLUGINS struct gaim_plugin { GModule *handle; char *name; char *description; }; struct gaim_callback { GModule *handle; enum gaim_event event; void *function; void *data; }; extern GList *plugins; extern GList *callbacks; #endif struct buddy { int edittype; /* CUI: this is really a GUI function and we need to put this in ui.h */ char name[80]; char show[80]; int present; int evil; time_t signon; time_t idle; int uc; gushort caps; /* woohoo! */ void *proto_data; /* what a hack */ struct gaim_connection *gc; /* the connection it belongs to */ }; struct group { int edittype; /* CUI: this is really a GUI function and we need to put this in ui.h */ char name[80]; GSList *members; struct gaim_connection *gc; /* the connection it belongs to */ }; /* Functions in buddy.c */ extern struct buddy *find_buddy(struct gaim_connection *, char *); extern struct group *find_group(struct gaim_connection *, char *); extern struct group *find_group_by_buddy(struct gaim_connection *, char *); extern struct buddy *add_buddy(struct gaim_connection *, char *, char *, char *); extern void remove_buddy(struct gaim_connection *, struct group *, struct buddy *); extern struct group *add_group(struct gaim_connection *, char *); extern void remove_group(struct gaim_connection *, struct group *); extern void do_export(struct gaim_connection *); extern void do_import(struct gaim_connection *, char *); extern int bud_list_cache_exists(struct gaim_connection *); /* Functions in server.c */ extern void serv_got_update(struct gaim_connection *, char *, int, int, time_t, time_t, int, gushort); extern void serv_got_im(struct gaim_connection *, char *, char *, guint32, time_t); extern void serv_got_eviled(struct gaim_connection *, char *, int); extern void serv_got_chat_invite(struct gaim_connection *, char *, char *, char *, GList *); extern struct conversation *serv_got_joined_chat(struct gaim_connection *, int, char *); extern void serv_got_chat_left(struct gaim_connection *, int); extern void serv_got_chat_in(struct gaim_connection *, int, char *, int, char *, time_t); extern void serv_finish_login(); #endif /* _CORE_H_ */ --- NEW FILE: ui.h --- /* * gaim * * Copyright (C) 1998-1999, Mark Spencer <mar...@ma...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #ifndef _UI_H_ #define _UI_H_ #ifdef HAVE_CONFIG_H #include <config.h> #endif #include <gtk/gtk.h> #ifdef USE_APPLET #include <applet-widget.h> #endif /* USE_APPLET */ #ifdef USE_GNOME #include <gnome.h> #endif #if USE_PIXBUF #include <gdk-pixbuf/gdk-pixbuf.h> #endif #define FACE_ANGEL 0 #define FACE_BIGSMILE 1 #define FACE_BURP 2 #define FACE_CROSSEDLIPS 3 #define FACE_CRY 4 #define FACE_EMBARRASSED 5 #define FACE_KISS 6 #define FACE_MONEYMOUTH 7 #define FACE_SAD 8 #define FACE_SCREAM 9 #define FACE_SMILE 10 #define FACE_SMILE8 11 #define FACE_THINK 12 #define FACE_TONGUE 13 #define FACE_WINK 14 #define FACE_YELL 15 #define FACE_TOTAL 16 struct debug_window { GtkWidget *window; GtkWidget *entry; }; extern struct debug_window *dw; /* CUI: save_pos and window_size are used by gaimrc.c which is core. * Need to figure out options saving. Same goes for several global variables as well. */ struct save_pos { int x; int y; int width; int height; int xoff; int yoff; }; struct window_size { int width; int height; int entry_height; }; #define EDIT_GC 0 #define EDIT_GROUP 1 #define EDIT_BUDDY 2 /* Globals in applet.c */ #ifdef USE_APPLET extern GtkWidget *applet; #endif /* USE_APPLET */ /* Globals in buddy.c */ extern GtkWidget *buddies; extern GtkWidget *bpmenu; extern GtkWidget *blist; /* Globals in buddy_chat.c */ /* it is very important that you don't use this for anything. * its sole purpose is to allow all group chats to be in one * window. use struct gaim_connection's buddy_chats instead. */ extern GList *chats; /* these are ok to use */ extern GtkWidget *all_chats; extern GtkWidget *chat_notebook; extern GtkWidget *joinchat; /* Globals in dialog.c */ extern char fontface[64]; extern int fontsize; extern GdkColor bgcolor; extern GdkColor fgcolor; extern int smiley_array[FACE_TOTAL]; /* Globals in prpl.c */ extern GtkWidget *protomenu; /* Functions in about.c */ extern void show_about(GtkWidget *, void *); extern void gaim_help(GtkWidget *, void *); #endif /* _UI_H_ */ Index: applet.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/applet.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- applet.h 2001/04/07 07:57:14 1.3 +++ applet.h 2001/10/03 09:48:33 1.4 @@ -28,8 +28,8 @@ ** Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA ** **************************************************************/ -#ifndef _GAIMGNOMEAPPLETMGR_H_ -#define _GAIMGNOMEAPPLETMGR_H_ +#ifndef _APPLET_H_ +#define _APPLET_H_ #ifdef USE_APPLET #include <gnome.h> @@ -84,4 +84,4 @@ extern gboolean applet_buddy_show; #endif /*USE_APPLET*/ -#endif /*_GAIMGNOMEAPPLETMGR_H_*/ +#endif /*_APPLET_H_*/ Index: convo.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/convo.h,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- convo.h 2001/09/28 12:15:54 1.11 +++ convo.h 2001/10/03 09:48:33 1.12 @@ -19,8 +19,8 @@ * */ -#ifndef _GAIMCONVO_H_ -#define _GAIMCONVO_H_ +#ifndef _CONVO_H_ +#define _CONVO_H_ #include <gtk/gtk.h> #include "gaim.h" @@ -74,4 +74,4 @@ extern gboolean meify(char *); -#endif +#endif /* _CONVO_H_ */ Index: gaim.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/gaim.h,v retrieving revision 1.275 retrieving revision 1.276 diff -u -d -r1.275 -r1.276 --- gaim.h 2001/10/03 07:49:38 1.275 +++ gaim.h 2001/10/03 09:48:33 1.276 @@ -19,23 +19,18 @@ * */ -#ifndef _GAIM_GAIM_H_ -#define _GAIM_GAIM_H_ +#ifndef _GAIM_H_ +#define _GAIM_H_ #ifdef HAVE_CONFIG_H #include <config.h> #endif -#include <gtk/gtk.h> -#include <time.h> -#include <stdio.h> -#ifdef USE_APPLET -#include <applet-widget.h> -#endif /* USE_APPLET */ -#ifdef USE_GNOME -#include <gnome.h> -#endif -#include "multi.h" +#include "core.h" +#include "ui.h" +/* CUI: when this is done being split, the only things below should be things + * both the core and the uis depend on e.g. the protocol definitions, etc, and + * it won't include core.h or ui.h (i.e. it'll mostly be #define's) */ #define BROWSER_NETSCAPE 0 @@ -74,28 +69,8 @@ #define AUTO_RESPONSE "<AUTO-REPLY> : " -#define PLUGIN_DIR ".gaim/plugins/" - #define WEBSITE "http://gaim.sourceforge.net/" -#define FACE_ANGEL 0 -#define FACE_BIGSMILE 1 -#define FACE_BURP 2 -#define FACE_CROSSEDLIPS 3 -#define FACE_CRY 4 -#define FACE_EMBARRASSED 5 -#define FACE_KISS 6 -#define FACE_MONEYMOUTH 7 -#define FACE_SAD 8 -#define FACE_SCREAM 9 -#define FACE_SMILE 10 -#define FACE_SMILE8 11 -#define FACE_THINK 12 -#define FACE_TONGUE 13 -#define FACE_WINK 14 -#define FACE_YELL 15 -#define FACE_TOTAL 16 - #ifndef USE_GNOME #ifdef ENABLE_NLS # include <libintl.h> @@ -111,8 +86,6 @@ #endif #endif -extern struct debug_window *dw; - struct aim_user { char username[64]; char password[32]; @@ -165,67 +138,6 @@ #define DEFAULT_INFO "Visit the GAIM website at <A HREF=\"http://gaim.sourceforge.net/\">http://gaim.sourceforge.net/</A>." -struct save_pos { - int x; - int y; - int width; - int height; - int xoff; - int yoff; -}; - - -struct window_size { - int width; - int height; - int entry_height; -}; - - -struct option_set { - int *options; - int option; -}; - -struct g_url { - char address[255]; - int port; - char page[255]; -}; - -enum gaim_event { - event_signon = 0, - event_signoff, - event_away, - event_back, - event_im_recv, - event_im_send, - event_buddy_signon, - event_buddy_signoff, - event_buddy_away, - event_buddy_back, - event_buddy_idle, - event_buddy_unidle, - event_blist_update, - event_chat_invited, - event_chat_join, - event_chat_leave, - event_chat_buddy_join, - event_chat_buddy_leave, - event_chat_recv, - event_chat_send, - event_warned, - event_error, - event_quit, - event_new_conversation, - event_set_info, - event_draw_menu, - event_im_displayed_sent, - event_im_displayed_rcvd, - event_chat_send_invite, - /* any others? it's easy to add... */ -}; - enum log_event { log_signon = 0, log_signoff, @@ -236,44 +148,6 @@ log_quit }; -#ifdef GAIM_PLUGINS -#include <gmodule.h> - -struct gaim_plugin { - GModule *handle; - char *name; - char *description; -}; - -struct gaim_callback { - GModule *handle; - enum gaim_event event; - void *function; - void *data; -}; - -extern GList *plugins; -extern GList *callbacks; -#endif - -#define EDIT_GC 0 -#define EDIT_GROUP 1 -#define EDIT_BUDDY 2 - -struct buddy { - int edittype; - char name[80]; - char show[80]; - int present; - int evil; - time_t signon; - time_t idle; - int uc; - gushort caps; /* woohoo! */ - void *proto_data; /* what a hack */ - struct gaim_connection *gc; /* the connection it belongs to */ -}; - struct log_conversation { char name[80]; char filename[512]; @@ -321,22 +195,6 @@ char message[2048]; }; -struct group { - int edittype; - char name[80]; - GSList *members; - struct gaim_connection *gc; /* the connection it belongs to */ -}; - -struct debug_window { - GtkWidget *window; - GtkWidget *entry; -}; - -#if USE_PIXBUF -#include <gdk-pixbuf/gdk-pixbuf.h> -#endif - /* struct buddy_chat went away and got merged with this. */ struct conversation { struct gaim_connection *gc; @@ -419,8 +277,6 @@ #define CONVERSATION_TITLE "%s - Gaim" #define LOG_CONVERSATION_TITLE "%s - Gaim (logged)" -#define AOL_SRCHSTR "/community/aimcheck.adp/url=" - /* These should all be runtime selectable */ #define MSG_LEN 2048 @@ -430,18 +286,6 @@ #define BUF_LEN MSG_LEN #define BUF_LONG BUF_LEN * 2 - -#ifdef USE_APPLET -extern GtkWidget *applet; -#endif /* USE_APPLET */ - -/* Globals in dialog.c */ -extern char fontface[64]; -extern int fontsize; -extern GdkColor bgcolor; -extern GdkColor fgcolor; -extern int smiley_array[FACE_TOTAL]; - /* Globals in aim.c */ extern GList *log_conversations; extern GList *buddy_pounces; @@ -452,16 +296,6 @@ extern char *opt_away_arg; extern char *opt_rcfile_arg; -/* Globals in buddy_chat.c */ -/* it is very important that you don't use this for anything. - * its sole purpose is to allow all group chats to be in one - * window. use struct gaim_connection's buddy_chats instead. */ -extern GList *chats; -extern GtkWidget *all_chats; -extern GtkWidget *chat_notebook; - -extern GtkWidget *joinchat; - /* Globals in away.c */ extern struct away_message *awaymessage; extern struct away_message *default_away; @@ -469,14 +303,6 @@ extern GtkWidget *awaymenu; extern GtkWidget *clistqueue; -/* Globals in prpl.c */ -extern GtkWidget *protomenu; - -/* Globals in buddy.c */ -extern GtkWidget *buddies; -extern GtkWidget *bpmenu; -extern GtkWidget *blist; - extern guint misc_options; #define OPT_MISC_DEBUG 0x00000001 #define OPT_MISC_BROWSER_POPUP 0x00000002 @@ -596,10 +422,6 @@ extern struct save_pos blist_pos; extern struct window_size conv_size, buddy_chat_size; -/* Functions in about.c */ -extern void show_about(GtkWidget *, void *); -extern void gaim_help(GtkWidget *, void *); - /* Functions in buddy_chat.c */ extern void join_chat(); extern void chat_write(struct conversation *, char *, int, char *, time_t); @@ -619,7 +441,6 @@ extern void chat_set_topic(struct conversation*, char*, char*); /* Functions in html.c */ -extern struct g_url parse_url(char *); extern void grab_url(char *, void (*callback)(gpointer, char *), gpointer); extern gchar *strip_html(gchar *); @@ -659,7 +480,6 @@ extern void serv_login(struct aim_user *); extern void serv_close(struct gaim_connection *); extern void serv_touch_idle(struct gaim_connection *); -extern void serv_finish_login(); extern int serv_send_im(struct gaim_connection *, char *, char *, int); extern void serv_get_info(struct gaim_connection *, char *); extern void serv_get_dir(struct gaim_connection *, char *); @@ -686,15 +506,6 @@ extern void serv_chat_whisper(struct gaim_connection *, int, char *, char *); extern int serv_chat_send(struct gaim_connection *, int, char *); -/* output from serv */ -extern void serv_got_update(struct gaim_connection *, char *, int, int, time_t, time_t, int, gushort); -extern void serv_got_im(struct gaim_connection *, char *, char *, guint32, time_t); -extern void serv_got_eviled(struct gaim_connection *, char *, int); -extern void serv_got_chat_invite(struct gaim_connection *, char *, char *, char *, GList *); -extern struct conversation *serv_got_joined_chat(struct gaim_connection *, int, char *); -extern void serv_got_chat_left(struct gaim_connection *, int); -extern void serv_got_chat_in(struct gaim_connection *, int, char *, int, char *, time_t); - /* Functions in conversation.c */ extern void gaim_setup_imhtml(GtkWidget *); extern void update_convo_add_button(struct conversation *); @@ -758,23 +569,13 @@ extern void signoff_all(gpointer, gpointer); extern void do_im_back(); extern void set_buddy(struct gaim_connection *, struct buddy *); -extern void add_category(char *); extern void build_edit_tree(); -extern void remove_person(struct group *, struct buddy *); -extern void remove_category(struct group *); extern void do_pounce(struct gaim_connection *, char *, int); extern void do_bp_menu(); -extern struct buddy *find_buddy(struct gaim_connection *, char *); -extern struct group *find_group(struct gaim_connection *, char *); -extern struct group *find_group_by_buddy(struct gaim_connection *, char *); -extern void remove_buddy(struct gaim_connection *, struct group *, struct buddy *); -extern void ui_remove_buddy(struct gaim_connection *, struct group *, struct buddy *); -extern struct buddy *add_buddy(struct gaim_connection *, char *, char *, char *); extern void ui_add_buddy(struct gaim_connection *, struct group *, struct buddy *); -extern void remove_group(struct gaim_connection *, struct group *); -extern void ui_remove_group(struct gaim_connection *, struct group *); -extern struct group *add_group(struct gaim_connection *, char *); +extern void ui_remove_buddy(struct gaim_connection *, struct group *, struct buddy *); extern void ui_add_group(struct gaim_connection *, struct group *); +extern void ui_remove_group(struct gaim_connection *, struct group *); extern void toggle_buddy_pixmaps(); extern void gaim_separator(GtkWidget *); extern void redo_buddy_list(); /* you really shouldn't call this function */ @@ -852,7 +653,6 @@ /* Functions in dialogs.c */ extern void alias_dialog_bud(struct buddy *); -extern void do_export(struct gaim_connection *); extern void show_warn_dialog(struct gaim_connection *, char *); extern GtkWidget *do_error_dialog(char *, char *); extern void show_im_dialog(); @@ -881,8 +681,6 @@ extern void show_ee_dialog(int); extern void show_add_link(GtkWidget *,struct conversation *); extern void show_change_passwd(struct gaim_connection *); -extern void do_import(struct gaim_connection *, char *); -extern int bud_list_cache_exists(struct gaim_connection *); extern void show_smiley_dialog(struct conversation *, GtkWidget *); extern void close_smiley_dialog(GtkWidget *widget, struct conversation *c); extern void set_smiley_array(GtkWidget *widget, int smiley_type); @@ -917,4 +715,4 @@ void BuddyTickerSetPixmap(char *, GdkPixmap *, GdkBitmap *); void BuddyTickerSignoff(); -#endif /* _GAIM_GAIM_H_ */ +#endif /* _GAIM_H_ */ Index: html.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/html.c,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- html.c 2001/09/27 19:17:10 1.20 +++ html.c 2001/10/03 09:48:33 1.21 @@ -36,6 +36,12 @@ #include <errno.h> #include "proxy.h" +struct g_url { + char address[255]; + int port; + char page[255]; +}; + gchar *strip_html(gchar *text) { int i, j, k; @@ -68,7 +74,7 @@ return text2; } -struct g_url parse_url(char *url) +static struct g_url parse_url(char *url) { struct g_url test; char scan_info[255]; Index: multi.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/multi.h,v retrieving revision 1.34 retrieving revision 1.35 diff -u -d -r1.34 -r1.35 --- multi.h 2001/10/01 07:50:07 1.34 +++ multi.h 2001/10/03 09:48:33 1.35 @@ -19,10 +19,10 @@ * */ -#ifndef _GAIMMULTI_H_ -#define _GAIMMULTI_H_ +#ifndef _MULTI_H_ +#define _MULTI_H_ -#include "gaim.h" +#include "core.h" /* ok. now the fun begins. first we create a connection structure */ struct gaim_connection { @@ -107,4 +107,4 @@ void set_login_progress(struct gaim_connection *, float, char *); void hide_login_progress(struct gaim_connection *, char *); -#endif /* _GAIMMULTI_H_ */ +#endif /* _MULTI_H_ */ Index: proxy.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/proxy.h,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- proxy.h 2001/07/31 23:23:40 1.7 +++ proxy.h 2001/10/03 09:48:33 1.8 @@ -23,8 +23,8 @@ prototype-ing stuff and redefine some net function to mask them with some kind of transparent layer */ -#ifndef _INC_PROXY_H -#define _INC_PROXY_H +#ifndef _PROXY_H_ +#define _PROXY_H_ #include <sys/types.h> #include <sys/socket.h> @@ -54,4 +54,4 @@ extern int proxy_connect(char *host, int port, GaimInputFunction func, gpointer data); -#endif +#endif /* _PROXY_H_ */ Index: prpl.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/prpl.c,v retrieving revision 1.36 retrieving revision 1.37 diff -u -d -r1.36 -r1.37 --- prpl.c 2001/10/01 14:54:37 1.36 +++ prpl.c 2001/10/03 09:48:33 1.37 @@ -19,6 +19,7 @@ * */ +#include "gaim.h" #include "prpl.h" #include <sys/types.h> #include <sys/stat.h> Index: prpl.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/prpl.h,v retrieving revision 1.49 retrieving revision 1.50 diff -u -d -r1.49 -r1.50 --- prpl.h 2001/10/02 05:52:56 1.49 +++ prpl.h 2001/10/03 09:48:33 1.50 @@ -19,11 +19,15 @@ * */ -#ifndef _GAIMPRPL_H_ -#define _GAIMPRPL_H_ +/* this file should be all that prpls need to include. therefore, by including + * this file, they should get glib, proxy, gaim_connection, prpl, etc. */ + +#ifndef _PRPL_H_ +#define _PRPL_H_ +#include "core.h" +#include "proxy.h" #include "multi.h" -#include <stdio.h> #define PROTO_TOC 0 #define PROTO_OSCAR 1 @@ -90,6 +94,12 @@ GList *(* chat_info)(struct gaim_connection *); /* all the server-related functions */ + + /* a lot of these (like get_dir) are protocol-dependent and should be removed. ones like + * set_dir (which is also protocol-dependent) can stay though because there's a dialog + * (i.e. the prpl says you can set your dir info, the ui shows a dialog and needs to call + * set_dir in order to set it) */ + void (* login) (struct aim_user *); void (* close) (struct gaim_connection *); int (* send_im) (struct gaim_connection *, char *who, char *message, int away); @@ -132,6 +142,7 @@ int (* chat_send) (struct gaim_connection *, int id, char *message); void (* keepalive) (struct gaim_connection *); + /* this is really bad. */ void (* convo_closed) (struct gaim_connection *, char *who); char *(* normalize)(const char *); @@ -157,4 +168,4 @@ extern void set_icon_data(struct gaim_connection *, char *, void *, int); extern void *get_icon_data(struct gaim_connection *, char *, int *); -#endif +#endif /* _PRPL_H_ */ |
From: Eric W. <war...@us...> - 2001-10-03 09:48:36
|
Update of /cvsroot/gaim/gaim/plugins In directory usw-pr-cvs1:/tmp/cvs-serv25541/plugins Modified Files: chatlist.c Log Message: boo-yah! Index: chatlist.c =================================================================== RCS file: /cvsroot/gaim/gaim/plugins/chatlist.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -d -r1.3 -r1.4 --- chatlist.c 2001/09/24 20:37:41 1.3 +++ chatlist.c 2001/10/03 09:48:33 1.4 @@ -11,6 +11,8 @@ #include <stdlib.h> #include <string.h> +#define AOL_SRCHSTR "/community/aimcheck.adp/url=" + struct chat_page { GtkWidget *list1; GtkWidget *list2; |
From: Eric W. <war...@us...> - 2001-10-03 09:48:36
|
Update of /cvsroot/gaim/gaim In directory usw-pr-cvs1:/tmp/cvs-serv25541 Modified Files: TODO Log Message: boo-yah! Index: TODO =================================================================== RCS file: /cvsroot/gaim/gaim/TODO,v retrieving revision 1.120 retrieving revision 1.121 diff -u -d -r1.120 -r1.121 --- TODO 2001/09/28 12:15:54 1.120 +++ TODO 2001/10/03 09:48:33 1.121 @@ -2,30 +2,29 @@ GPG Encryption of messages Have plugin_event use varargs instead of void* Separate core functions from UI stuff. - about.c, applet.[ch], away.c, buddy.c, conversation.c, convo.h, - dialogs.c, multi.c, gtk*, prefs.c, prpl.c, sound.c, ticker.c + about.c, applet.[ch], away.c, browser.c, buddy.c, conversation.c, + convo.h, dialogs.c, gtk*, plugins.c, prefs.c, prpl.c, sound.c, + ticker.c, ui.h little to no work (mostly GTK) - gaimrc.c, html.c, list.c, proxy.[ch], prpl.h, server.c, util.c + core.[ch], html.c, list.c, module.c, multi.h, proxy.[ch], perl.c, + prpl.h, util.c little to no work (mostly CORE) + buddy_chat.c, gaim.h, idle.c, multi.c, server.c + standard splitting (for idleness, core needs to be in + charge of gaim-use idleness) + aim.c - need to redo main() completely - current main should be moved mostly to core - GTK main should connect to core - browser.c - let the UI deal with this? little to no work. - buddy_chat.c - need to move out non-GTK functions. some work. - gaim.h - need to separate into core.h and ui.h. - idle.c - Need to figure out how to report idle times when there's - more than one UI - multi.h - need to separate GTK out of gaim_connection - perl.c - Uh. Might need to do some splitting. - plugins.c - Split the selection dialog with the loading/unloading - - Need to figure out how plugins are going to interact - with UIs, though UIs are separate programs. - Need to create struct buddy_chat, move struct conversation's in_room and - ignored there, and copy id and name. + gaimrc.c - Need to figure out how to save UI preferences + + Ideally at the end of this the prpls should only need to include + prpl.h and they'll get everything they need without anything + *cough*GTK*cough* that they don't. + Need to write the core side of the core-ui protocol - Need to add in core.c to deal with sockets, etc. (Already written) ---- THE PROTOCOLS: @@ -75,6 +74,11 @@ Zephyr: God help us. +Gadu-Gadu: + New User Registration + There's probably 100 other things but since I've hardly used the Windows + client before I'm not sure what any of them are + Future Plugins? : ICQ through Oscar plugin (ICQ2000) (requires hacking libfaim :-/) this would allow us to send SMS messages. @@ -101,6 +105,8 @@ all of the custom messages, e.g. in Jabber it'd return "Away/" as one of the states, and you'd see "Away" with a menu of all the away messages you have. + + Need to write the ui side of the core-ui protocol Syd is cool and gave all of these ideas: Have multiple tickers in the same window, one for buddies |
From: Eric W. <war...@us...> - 2001-10-03 09:48:36
|
Update of /cvsroot/gaim/gaim/src/protocols/zephyr In directory usw-pr-cvs1:/tmp/cvs-serv25541/src/protocols/zephyr Modified Files: zephyr.c Log Message: boo-yah! Index: zephyr.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/zephyr/zephyr.c,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- zephyr.c 2001/09/28 07:46:36 1.12 +++ zephyr.c 2001/10/03 09:48:33 1.13 @@ -373,11 +373,7 @@ away = TRUE; else away = FALSE; - len = MAX(BUF_LONG, strlen(buf2)); - buf = g_malloc(len + 1); - g_snprintf(buf, len + 1, "%s", buf2); - serv_got_im(zgc, notice.z_sender, buf, 0, time((time_t)NULL)); - g_free(buf); + serv_got_im(zgc, notice.z_sender, buf2, 0, time((time_t)NULL)); } else { zephyr_triple *zt1, *zt2; zt1 = new_triple(notice.z_class, notice.z_class_inst, @@ -386,16 +382,12 @@ if (!zt2) { /* we shouldn't be subscribed to this message. ignore. */ } else { - len = MAX(BUF_LONG, strlen(buf2)); - buf = g_malloc(len + 1); - g_snprintf(buf, len + 1, "%s", buf2); if (!zt2->open) { zt2->open = TRUE; serv_got_joined_chat(zgc, zt2->id, zt2->name); } serv_got_chat_in(zgc, zt2->id, notice.z_sender, FALSE, - buf, time((time_t)NULL)); - g_free(buf); + buf2, time((time_t)NULL)); } free_triple(zt1); } |
From: Eric W. <war...@us...> - 2001-10-03 07:49:41
|
Update of /cvsroot/gaim/gaim In directory usw-pr-cvs1:/tmp/cvs-serv2872 Modified Files: acconfig.h configure.ac Log Message: core.c. There's nothing here yet and nothing in it is used by default (though most of it is compiled). i need to split gaim.h into core.h and ui.h next. oh, and split struct conversation and move it completely out of the prpls. Index: acconfig.h =================================================================== RCS file: /cvsroot/gaim/gaim/acconfig.h,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- acconfig.h 2001/09/29 23:06:29 1.12 +++ acconfig.h 2001/10/03 07:49:38 1.13 @@ -19,6 +19,7 @@ #undef NEED_GNOMESUPPORT_H #undef ZEPHYR_INT32 #undef ZEPHYR_USES_KERBEROS +#undef DEVEL #ifndef STATIC_PROTO_INIT #undef STATIC_PROTO_INIT #endif Index: configure.ac =================================================================== RCS file: /cvsroot/gaim/gaim/configure.ac,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- configure.ac 2001/10/01 07:09:09 1.16 +++ configure.ac 2001/10/03 07:49:38 1.17 @@ -41,6 +41,11 @@ CFLAGS="$CFLAGS -I/usr/local/include -I/opt/include -I\$(top_srcdir)" AC_ARG_ENABLE(distrib,,,enable_distrib=no) +AC_ARG_ENABLE(devel,,,enable_devel=no) +if test "$enable_devel" = "yes" ; then + CFLAGS="$CFLAGS -Wall" + AC_DEFINE(DEVEL) +fi AM_CONDITIONAL(DISTRIB, test "x$enable_distrib" = "xyes") AC_ARG_ENABLE(multi, [ --disable-multi disable multiple connections],,enable_multi=yes) AC_ARG_ENABLE(prpls, [ --disable-prpls don't build dynamic protocol plugins],,enable_prpls=yes) @@ -95,7 +100,7 @@ AC_ARG_ENABLE(plugins, [ --disable-plugins compile without plugin support],,enable_plugins=yes) AC_ARG_ENABLE(perl, [ --disable-perl compile without perl scripting],,enable_perl=yes) -AC_ARG_ENABLE(debug, [ --enable-debug compile with debugging support],,enable_debug=no) +AC_ARG_ENABLE(debug, [ --enable-debug compile with debugging support],,enable_debug=$enable_devel) AC_ARG_ENABLE(screensaver, [ --disable-screensaver compile without X screensaver extension],,enable_xss=yes) AC_ARG_WITH(krb4, [ --with-krb4=PREFIX Compile Zephyr plugin with Kerberos 4 support],kerberos="$withval",kerberos="no") |
From: Eric W. <war...@us...> - 2001-10-03 07:49:41
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv2872/src Modified Files: Makefile.am aim.c gaim.h Added Files: core.c Log Message: core.c. There's nothing here yet and nothing in it is used by default (though most of it is compiled). i need to split gaim.h into core.h and ui.h next. oh, and split struct conversation and move it completely out of the prpls. --- NEW FILE: core.c --- /* * gaim * * Copyright (C) 1998-1999, Mark Spencer <mar...@ma...> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #ifdef HAVE_CONFIG_H #include "config.h" #endif #include <glib.h> #include <stdio.h> #include <stdlib.h> #include <sys/types.h> #include <sys/socket.h> #include <sys/stat.h> #include <sys/un.h> #include <unistd.h> #include <errno.h> #include <signal.h> #include <getopt.h> #include "gaim.h" static gint UI_fd = -1; struct UI { GIOChannel *channel; guint inpa; }; GSList *uis = NULL; static gint gaim_recv(GIOChannel *source, guchar *buf, gint len) { gint total = 0; gint cur; while (total < len) { if (g_io_channel_read(source, buf + total, len - total, &cur) != G_IO_ERROR_NONE) return -1; if (cur == 0) return total; total += cur; } return total; } static gboolean UI_readable(GIOChannel *source, GIOCondition cond, gpointer data) { struct UI *ui = data; guchar buf[2] = {0, 0}; guint32 len; guchar *in; gushort type; /* buf[0] is to specify gaim, buf[1] is for protocol version */ if ((gaim_recv(source, buf, 2) != 2) || (buf[0] != 102) || (buf[1] != 1)) { debug_printf("UI has abandoned us! (%d %d)\n", buf[0], buf[1]); uis = g_slist_remove(uis, ui); g_io_channel_close(ui->channel); g_source_remove(ui->inpa); g_free(ui); return FALSE; } /* no byte order worries! this'll change if we go to TCP */ if (gaim_recv(source, (guchar *)&len, sizeof(len)) != sizeof(len)) { debug_printf("UI has abandoned us!\n"); uis = g_slist_remove(uis, ui); g_io_channel_close(ui->channel); g_source_remove(ui->inpa); g_free(ui); return FALSE; } in = g_new0(guchar, len + 1); gaim_recv(source, in, len); memcpy(&type, in, sizeof(type)); switch (type) { /* case CUI_TYPE_META: meta_handler(ui, in); break; case CUI_TYPE_PLUGIN: plugin_handler(ui, in); break; case CUI_TYPE_USER: user_handler(ui, in); break; case CUI_TYPE_CONN: conn_handler(ui, in); break; case CUI_TYPE_BUDDY: buddy_handler(ui, in); break; case CUI_TYPE_MESSAGE: message_handler(ui, in); break; case CUI_TYPE_CHAT: chat_handler(ui, in); break; */ default: debug_printf("unhandled type %d\n", type); break; } g_free(in); return TRUE; } static gboolean socket_readable(GIOChannel *source, GIOCondition cond, gpointer data) { struct sockaddr_un saddr; gint len; gint fd; struct UI *ui; if ((fd = accept(UI_fd, (struct sockaddr *)&saddr, &len)) == -1) return FALSE; ui = g_new0(struct UI, 1); uis = g_slist_append(uis, ui); ui->channel = g_io_channel_unix_new(fd); ui->inpa = g_io_add_watch(ui->channel, G_IO_IN | G_IO_HUP | G_IO_ERR, UI_readable, ui); g_io_channel_unref(ui->channel); debug_printf("got one\n"); return TRUE; } static gint open_socket() { struct sockaddr_un saddr; gint fd; if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) != -1) { umask(0177); saddr.sun_family = AF_UNIX; g_snprintf(saddr.sun_path, 108, "%s/gaim_%s.%d", g_get_tmp_dir(), g_get_user_name(), getpid()); if (bind(fd, (struct sockaddr *)&saddr, sizeof(saddr)) != -1) listen(fd, 100); else g_log(NULL, G_LOG_LEVEL_CRITICAL, "Failed to assign %s to a socket (Error: %s)", saddr.sun_path, strerror(errno)); } else g_log(NULL, G_LOG_LEVEL_CRITICAL, "Unable to open socket: %s", strerror(errno)); return fd; } int core_main() { /* GMainLoop *loop; */ #if DEVEL GIOChannel *channel; UI_fd = open_socket(); if (UI_fd < 0) return 1; channel = g_io_channel_unix_new(UI_fd); g_io_add_watch(channel, G_IO_IN, socket_readable, NULL); g_io_channel_unref(channel); #endif /* loop = g_main_new(TRUE); g_main_run(loop); */ return 0; } void core_quit() { #ifdef DEVEL char buf[1024]; close(UI_fd); sprintf(buf, "%s/gaim_%s.%d", g_get_tmp_dir(), g_get_user_name(), getpid()); unlink(buf); #endif } Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/Makefile.am,v retrieving revision 1.40 retrieving revision 1.41 diff -u -d -r1.40 -r1.41 --- Makefile.am 2001/09/29 23:06:30 1.40 +++ Makefile.am 2001/10/03 07:49:38 1.41 @@ -10,6 +10,7 @@ buddy.c \ buddy_chat.c \ conversation.c \ + core.c \ dialogs.c \ gaimrc.c \ gtkimhtml.c \ @@ -42,6 +43,7 @@ buddy.c \ buddy_chat.c \ conversation.c \ + core.c \ dialogs.c \ gaimrc.c \ gtkimhtml.c \ Index: aim.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/aim.c,v retrieving revision 1.161 retrieving revision 1.162 diff -u -d -r1.161 -r1.162 --- aim.c 2001/09/30 19:58:48 1.161 +++ aim.c 2001/10/03 07:49:38 1.162 @@ -382,6 +382,7 @@ signoff_all(NULL, NULL); break; case SIGSEGV: + core_quit(); fprintf(stderr, "Gaim has segfaulted and attempted to dump a core file.\n" "This is a bug in the software and has happened through\n" "no fault of your own.\n\n" @@ -408,6 +409,7 @@ #endif if (gtk_main_level()) gtk_main_quit(); + core_quit(); exit(0); } } @@ -620,6 +622,8 @@ load_prefs(); + core_main(); + /* set the default username */ if (opt_user_arg != NULL) { set_first_user(opt_user_arg); @@ -678,6 +682,7 @@ #endif /* USE_APPLET */ gtkspell_stop(); + core_quit(); return 0; Index: gaim.h =================================================================== RCS file: /cvsroot/gaim/gaim/src/gaim.h,v retrieving revision 1.274 retrieving revision 1.275 diff -u -d -r1.274 -r1.275 --- gaim.h 2001/10/02 05:52:56 1.274 +++ gaim.h 2001/10/03 07:49:38 1.275 @@ -906,6 +906,10 @@ /* Functions in multi.c */ extern void account_editor(GtkWidget *, GtkWidget *); +/* Functions in core.c */ /* Don't ever use these */ +extern int core_main(); +extern void core_quit(); + /* fucntions in ticker.c */ void SetTickerPrefs(); void BuddyTickerSignOff(); |
From: Eric W. <war...@us...> - 2001-10-03 06:04:47
|
Update of /cvsroot/gaim/gaim In directory usw-pr-cvs1:/tmp/cvs-serv10984 Modified Files: autogen.sh Log Message: this fixes distcheck for automake 1.5 and doesn't break it for 1.4. Index: autogen.sh =================================================================== RCS file: /cvsroot/gaim/gaim/autogen.sh,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- autogen.sh 2001/09/12 22:47:44 1.10 +++ autogen.sh 2001/10/03 06:04:44 1.11 @@ -47,5 +47,6 @@ autoheader; automake --add-missing --copy; autoconf; +automake; ./configure $@ |
From: Eric W. <war...@us...> - 2001-10-03 06:04:47
|
Update of /cvsroot/gaim/gaim/src/protocols In directory usw-pr-cvs1:/tmp/cvs-serv10984/src/protocols Modified Files: Makefile.am Log Message: this fixes distcheck for automake 1.5 and doesn't break it for 1.4. Index: Makefile.am =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/Makefile.am,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- Makefile.am 2001/09/29 23:06:30 1.2 +++ Makefile.am 2001/10/03 06:04:44 1.3 @@ -1,6 +1,8 @@ +DIST_SUBDIRS = gg icq irc jabber msn napster oscar toc yahoo zephyr + if PRPLS -SUBDIRS = gg icq irc jabber msn napster oscar toc yahoo zephyr +SUBDIRS = $(DIST_SUBDIRS) else |
From: Eric W. <war...@us...> - 2001-10-03 03:11:40
|
Update of /cvsroot/gaim/gaim/src In directory usw-pr-cvs1:/tmp/cvs-serv22398 Modified Files: module.c Log Message: hi. Index: module.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/module.c,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- module.c 2001/10/01 15:49:04 1.2 +++ module.c 2001/10/03 03:11:37 1.3 @@ -34,6 +34,8 @@ #include <config.h> #endif +#include "gaim.h" + #ifdef GAIM_PLUGINS #include <string.h> @@ -45,7 +47,6 @@ #include <unistd.h> #include <stdio.h> #include <stdlib.h> -#include "gaim.h" /* ------------------ Global Variables ----------------------- */ |
From: Eric W. <war...@us...> - 2001-10-02 20:31:59
|
Update of /cvsroot/gaim/gaim/src/protocols/irc In directory usw-pr-cvs1:/tmp/cvs-serv19097/protocols/irc Modified Files: irc.c Log Message: (13:31:13) DennisR: warmenhoven: You should change "Unsupported command" to "Unknown command" (/scan is a real command, but /asdkjhfasdasdfhjk isnt, and both say unsupported command =)) Index: irc.c =================================================================== RCS file: /cvsroot/gaim/gaim/src/protocols/irc/irc.c,v retrieving revision 1.38 retrieving revision 1.39 diff -u -d -r1.38 -r1.39 --- irc.c 2001/09/30 05:16:30 1.38 +++ irc.c 2001/10/02 20:31:56 1.39 @@ -1216,7 +1216,7 @@ } if (!c) return -EINVAL; - write_to_conv(c, "<B>Unsupported command</B>", WFLAG_SYSTEM, NULL, time(NULL)); + write_to_conv(c, "<B>Unknown command</B>", WFLAG_SYSTEM, NULL, time(NULL)); } return 0; |