]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
pam: fix typo
authorChristian Brauner <christian.brauner@ubuntu.com>
Tue, 12 Jun 2018 13:03:38 +0000 (15:03 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Tue, 12 Jun 2018 13:05:44 +0000 (15:05 +0200)
fixes commit 2dce415b621e ("fix getpwnam() thread safe issue")

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/pam/pam_cgfs.c

index 81ce912e8fb5a1cac4204a2b3d6b08e1fb1669de..8e7404400b10086a9812592c22ca67f0d4c78850 100644 (file)
@@ -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;