Mercurial > pidgin
diff plugins/yay/login.c @ 1655:a4f1f8d429fb
[gaim-migrate @ 1665]
better login? identities? maybe?
committer: Tailor Script <tailor@pidgin.im>
| author | Eric Warmenhoven <eric@warmenhoven.org> |
|---|---|
| date | Tue, 27 Mar 2001 22:09:21 +0000 |
| parents | 2c66d386be90 |
| children | dff412b306b8 |
line wrap: on
line diff
--- a/plugins/yay/login.c Tue Mar 27 21:39:23 2001 +0000 +++ b/plugins/yay/login.c Tue Mar 27 22:09:21 2001 +0000 @@ -64,7 +64,7 @@ int yahoo_finish_logon(struct yahoo_session *session, enum yahoo_status status) { - char *buf = NULL; + char *buf = NULL, *tmp = NULL; int ret; struct yahoo_conn *conn; @@ -74,11 +74,21 @@ if (!(conn = yahoo_getconn_type(session, YAHOO_CONN_TYPE_MAIN))) return 0; - if (!(buf = g_strconcat(session->login_cookie, "\001", session->name, NULL))) + if (session->identities) { + if (!(tmp = g_strjoinv(",", session->identities))) + return 0; + } else + tmp = ""; + + if (!(buf = g_strconcat(session->login_cookie, "\001", session->name, tmp, NULL))) { + g_free(tmp); return 0; + } ret = yahoo_write_cmd(session, conn, YAHOO_SERVICE_LOGON, session->name, buf, status); g_free(buf); + if (session->identities) + g_free(tmp); return ret; }
