If a username gets changed and auth cache is in use, auth-workers for
blocking userdb did not update the username in cache. This is now
fixed by setting user_changed_by_lookup in case the username changed.
args = "";
else
username = t_strdup_until(username, args++);
- if (username[0] != '\0' && strcmp(request->user, username) != 0)
+ if (username[0] != '\0' && strcmp(request->user, username) != 0) {
request->user = p_strdup(request->pool, username);
+ request->user_changed_by_lookup = TRUE;
+ }
} else {
result = USERDB_RESULT_INTERNAL_FAILURE;
i_error("BUG: auth-worker sent invalid user reply");