pam: fix typo

fixes commit 2dce415b ("fix getpwnam() thread safe issue") Signed-off-by: 's avatarChristian Brauner <christian.brauner@ubuntu.com>
parent 5465e673
......@@ -1520,7 +1520,7 @@ static void cg_escape(void)
/* Get uid and gid for @user. */
static bool get_uid_gid(const char *user, uid_t *uid, gid_t *gid)
{
strcut passwd pwent;
struct passwd pwent;
struct passwd *pwentp = NULL;
char *buf;
size_t bufsize;
......@@ -1537,7 +1537,8 @@ static bool get_uid_gid(const char *user, uid_t *uid, gid_t *gid)
ret = getpwnam_r(user, &pwent, buf, bufsize, &pwentp);
if (!pwentp) {
if (ret == 0)
mysyslog(LOG_ERR, "Could not find matched password record.\n", NULL);
mysyslog(LOG_ERR,
"Could not find matched password record\n", NULL);
free(buf);
return false;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment