dovecot: Userdb prefetch didn't work with blocking passdbs.
dovecot at dovecot.org
dovecot at dovecot.org
Mon Aug 6 17:45:28 EEST 2007
details: http://hg.dovecot.org/dovecot/rev/370691a10003
changeset: 6173:370691a10003
user: Timo Sirainen <tss at iki.fi>
date: Mon Aug 06 17:45:25 2007 +0300
description:
Userdb prefetch didn't work with blocking passdbs.
diffstat:
1 file changed, 18 insertions(+)
src/auth/auth-worker-client.c | 18 ++++++++++++++++++
diffs (42 lines):
diff -r b31c368b150b -r 370691a10003 src/auth/auth-worker-client.c
--- a/src/auth/auth-worker-client.c Mon Aug 06 17:30:03 2007 +0300
+++ b/src/auth/auth-worker-client.c Mon Aug 06 17:45:25 2007 +0300
@@ -71,6 +71,14 @@ worker_auth_request_new(struct auth_work
}
return auth_request;
+}
+
+static void add_userdb_replies(string_t *str, const char *data)
+{
+ const char *const *tmp;
+
+ for (tmp = t_strsplit(data, "\t"); *tmp != NULL; tmp++)
+ str_printfa(str, "\tuserdb_%s", *tmp);
}
static void verify_plain_callback(enum passdb_result result,
@@ -102,6 +110,11 @@ static void verify_plain_callback(enum p
str_append_c(str, '\t');
str_append(str, field);
}
+ if (request->userdb_reply != NULL) {
+ const char *data =
+ auth_stream_reply_export(request->userdb_reply);
+ add_userdb_replies(str, data);
+ }
}
str_append_c(str, '\n');
o_stream_send(client->output, str_data(str), str_len(str));
@@ -190,6 +203,11 @@ lookup_credentials_callback(enum passdb_
const char *field =
auth_stream_reply_export(request->extra_fields);
str_append(str, field);
+ }
+ if (request->userdb_reply != NULL) {
+ const char *data =
+ auth_stream_reply_export(request->userdb_reply);
+ add_userdb_replies(str, data);
}
}
str_append_c(str, '\n');
More information about the dovecot-cvs
mailing list