From 337518b1f422f70c64d535820fcda70e5b10c462 Mon Sep 17 00:00:00 2001
From: Miklos Vajna <vmiklos@frugalware.org>
Date: Sat, 20 Mar 2010 02:20:36 +0100
Subject: [PATCH] Oscar: add an ignore_add setting to be able to ignore additions
This sounds crazy for the first time, but given how much of us just use
oscar these days without willing to add anyone - and seeing how much
spam do we get via those irritating oscar requests, it makes sense.
---
protocols/oscar/oscar.c | 9 ++++++++-
1 files changed, 8 insertions(+), 1 deletions(-)
diff --git a/protocols/oscar/oscar.c b/protocols/oscar/oscar.c
index f0e65f9..9508b59 100644
a
|
b
|
static void oscar_init(account_t *acc) |
379 | 379 | s = set_add( &acc->set, "web_aware", "false", set_eval_bool, acc ); |
380 | 380 | s->flags |= ACC_SET_OFFLINE_ONLY; |
381 | 381 | } |
| 382 | |
| 383 | set_add(&acc->set, "ignore_add", "false", set_eval_bool, acc); |
382 | 384 | |
383 | 385 | acc->flags |= ACC_FLAG_AWAY_MESSAGE; |
384 | 386 | } |
… |
… |
static void gaim_icq_authdeny(void *data_) { |
1211 | 1213 | * For when other people ask you for authorization |
1212 | 1214 | */ |
1213 | 1215 | static void gaim_icq_authask(struct im_connection *ic, guint32 uin, char *msg) { |
1214 | | struct icq_auth *data = g_new(struct icq_auth, 1); |
| 1216 | struct icq_auth *data; |
1215 | 1217 | char *reason = NULL; |
1216 | 1218 | char *dialog_msg; |
| 1219 | |
| 1220 | if (set_getbool(&ic->acc->set, "ignore_add")) |
| 1221 | return; |
1217 | 1222 | |
| 1223 | data = g_new(struct icq_auth, 1); |
| 1224 | |
1218 | 1225 | if (strlen(msg) > 6) |
1219 | 1226 | reason = msg + 6; |
1220 | 1227 | |