comparison src/prpl.c @ 981:7e231bc0018a

[gaim-migrate @ 991] I think I need a Pepsi. committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Fri, 13 Oct 2000 07:24:40 +0000
parents
children 91b7377e7b45
comparison
equal deleted inserted replaced
980:82c5865f7cfe 981:7e231bc0018a
1 /*
2 * gaim
3 *
4 * Copyright (C) 1998-1999, Mark Spencer <markster@marko.net>
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 *
20 */
21
22 #include "prpl.h"
23 extern struct prpl *toc_init();
24 extern struct prpl *oscar_init();
25
26 GSList *protocols = NULL;
27
28 struct prpl *find_prpl(int prot)
29 {
30 GSList *e = protocols;
31 struct prpl *r;
32
33 while (e) {
34 r = (struct prpl *)e->data;
35 if (r->protocol == prot)
36 return r;
37 e = e->next;
38 }
39
40 return NULL;
41 }
42
43 void static_proto_init()
44 {
45 protocols = g_slist_append(protocols, toc_init());
46 #ifndef DYNAMIC_OSCAR
47 protocols = g_slist_append(protocols, oscar_init());
48 #endif
49 }