Mercurial > pidgin
diff src/server.c @ 4227:a614423c648f
[gaim-migrate @ 4471]
This is a patch from Nathan Walp that adds a
"char server_alias[BUDDY_ALIAS_MAXLEN]" to struct buddy, and a preference
option to show the server alias instead of the alias set by you. It
shouldn't cause any problems. But then again, faceprint is a crazy patch
writer, with an emphasis on crazy, if you know what I mean. Huh? Get it?
"Crazy"? I kill me. But right after I kill Time Warner.
committer: Tailor Script <tailor@pidgin.im>
| author | Mark Doliner <mark@kingant.net> |
|---|---|
| date | Tue, 07 Jan 2003 17:44:34 +0000 |
| parents | 511c2b63caa4 |
| children | ff0642fab1d5 |
line wrap: on
line diff
--- a/src/server.c Tue Jan 07 16:18:08 2003 +0000 +++ b/src/server.c Tue Jan 07 17:44:34 2003 +0000 @@ -340,6 +340,19 @@ } } +void serv_got_alias(struct gaim_connection *gc, char *who, char *alias) { + struct buddy *b = find_buddy(gc, who); + if(!b) + return; + + if(alias) + g_snprintf(b->server_alias, sizeof(b->server_alias), "%s", alias); + else + b->server_alias[0] = '\0'; + + handle_buddy_rename(b, b->name); +} + /* * Move a buddy from one group to another on server. * @@ -612,7 +625,7 @@ time_t t; char *tmpmsg; struct buddy *b = find_buddy(gc, name); - char *alias = b ? b->show : name; + char *alias = b ? get_buddy_alias(b) : name; int row; struct queued_away_response *qar;
