comparison src/server.c @ 10850:fa06fda62868

[gaim-migrate @ 12522] GET OUTTA MY HOUSE!!! Thanks to Gary for showing me a list of non-namespaced stuff. I'm sure I missed some. committer: Tailor Script <tailor@pidgin.im>
author Mark Doliner <mark@kingant.net>
date Tue, 19 Apr 2005 04:43:13 +0000
parents 53e7884c549a
children 2409700be3dc
comparison
equal deleted inserted replaced
10849:c203cd637f95 10850:fa06fda62868
77 GaimConnection *gc; 77 GaimConnection *gc;
78 char name[80]; 78 char name[80];
79 time_t sent; 79 time_t sent;
80 }; 80 };
81 81
82 gboolean expire_last_auto_responses(gpointer data) 82 static gboolean
83 expire_last_auto_responses(gpointer data)
83 { 84 {
84 GSList *tmp, *cur; 85 GSList *tmp, *cur;
85 struct last_auto_response *lar; 86 struct last_auto_response *lar;
86 87
87 tmp = last_auto_responses; 88 tmp = last_auto_responses;
98 } 99 }
99 100
100 return FALSE; /* do not run again */ 101 return FALSE; /* do not run again */
101 } 102 }
102 103
103 struct last_auto_response *get_last_auto_response(GaimConnection *gc, const char *name) 104 static struct last_auto_response *
105 get_last_auto_response(GaimConnection *gc, const char *name)
104 { 106 {
105 GSList *tmp; 107 GSList *tmp;
106 struct last_auto_response *lar; 108 struct last_auto_response *lar;
107 109
108 /* because we're modifying or creating a lar, schedule the 110 /* because we're modifying or creating a lar, schedule the
125 lar->gc = gc; 127 lar->gc = gc;
126 lar->sent = 0; 128 lar->sent = 0;
127 last_auto_responses = g_slist_append(last_auto_responses, lar); 129 last_auto_responses = g_slist_append(last_auto_responses, lar);
128 130
129 return lar; 131 return lar;
130 }
131
132 void flush_last_auto_responses(GaimConnection *gc)
133 {
134 GSList *tmp, *cur;
135 struct last_auto_response *lar;
136
137 tmp = last_auto_responses;
138
139 while (tmp) {
140 cur = tmp;
141 tmp = tmp->next;
142 lar = (struct last_auto_response *)cur->data;
143
144 if (lar->gc == gc) {
145 last_auto_responses = g_slist_remove(last_auto_responses, lar);
146 g_free(lar);
147 }
148 }
149 } 132 }
150 133
151 int serv_send_im(GaimConnection *gc, const char *name, const char *message, 134 int serv_send_im(GaimConnection *gc, const char *name, const char *message,
152 GaimConvImFlags imflags) 135 GaimConvImFlags imflags)
153 { 136 {