View | Details | Raw Unified | Return to bug 1595 | Differences between
and this patch

Collapse All | Expand All

(-)port-aix.c (-2 / +3 lines)
Lines 271-292 Link Here
271
	return permitted;
271
	return permitted;
272
}
272
}
273
273
274
int
274
int
275
sys_auth_record_login(const char *user, const char *host, const char *ttynm,
275
sys_auth_record_login(const char *user, const char *host, const char *ttynm,
276
    Buffer *loginmsg)
276
    Buffer *loginmsg, int print_lastlog)
277
{
277
{
278
	char *msg = NULL;
278
	char *msg = NULL;
279
	static int msg_done = 0;
279
	static int msg_done = 0;
280
	int success = 0;
280
	int success = 0;
281
281
282
	aix_setauthdb(user);
282
	aix_setauthdb(user);
283
	if (loginsuccess((char *)user, (char *)host, (char *)ttynm, &msg) == 0) {
283
	if (loginsuccess((char *)user, (char *)host, (char *)ttynm, &msg) == 0) {
284
		success = 1;
284
		success = 1;
285
		if (msg != NULL && loginmsg != NULL && !msg_done) {
285
		if (msg != NULL && loginmsg != NULL && !msg_done) {
286
			debug("AIX/loginsuccess: msg %s", msg);
286
			debug("AIX/loginsuccess: msg %s", msg);
287
			buffer_append(loginmsg, msg, strlen(msg));
287
			if(print_lastlog)
288
				buffer_append(loginmsg, msg, strlen(msg));
288
			xfree(msg);
289
			xfree(msg);
289
			msg_done = 1;
290
			msg_done = 1;
290
		}
291
		}
291
	}
292
	}
292
	aix_restoreauthdb();
293
	aix_restoreauthdb();

Return to bug 1595