From owner-svn-src-all@FreeBSD.ORG Mon Sep 29 11:24:22 2014 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id DEA54567; Mon, 29 Sep 2014 11:24:21 +0000 (UTC) Received: from mx1.sbone.de (bird.sbone.de [46.4.1.90]) (using TLSv1 with cipher DHE-RSA-CAMELLIA256-SHA (256/256 bits)) (Client CN "mx1.sbone.de", Issuer "SBone.DE" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id AFA08A7A; Mon, 29 Sep 2014 11:23:43 +0000 (UTC) Received: from mail.sbone.de (mail.sbone.de [IPv6:fde9:577b:c1a9:31::2013:587]) (using TLSv1 with cipher ADH-CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by mx1.sbone.de (Postfix) with ESMTPS id 2DD4325D37C3; Mon, 29 Sep 2014 11:21:28 +0000 (UTC) Received: from content-filter.sbone.de (content-filter.sbone.de [IPv6:fde9:577b:c1a9:31::2013:2742]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPS id ADCA9C77108; Mon, 29 Sep 2014 11:21:27 +0000 (UTC) X-Virus-Scanned: amavisd-new at sbone.de Received: from mail.sbone.de ([IPv6:fde9:577b:c1a9:31::2013:587]) by content-filter.sbone.de (content-filter.sbone.de [fde9:577b:c1a9:31::2013:2742]) (amavisd-new, port 10024) with ESMTP id kII1DuTQlS0F; Mon, 29 Sep 2014 11:21:26 +0000 (UTC) Received: from [IPv6:fde9:577b:c1a9:4410:80e5:6a63:fe7c:9e54] (unknown [IPv6:fde9:577b:c1a9:4410:80e5:6a63:fe7c:9e54]) (using TLSv1 with cipher AES128-SHA (128/128 bits)) (No client certificate requested) by mail.sbone.de (Postfix) with ESMTPSA id 5AF6CC77107; Mon, 29 Sep 2014 11:21:23 +0000 (UTC) Content-Type: text/plain; charset=windows-1252 Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: svn commit: r272281 - head/lib/libpam/modules/pam_login_access From: "Bjoern A. Zeeb" In-Reply-To: Date: Mon, 29 Sep 2014 11:20:20 +0000 Content-Transfer-Encoding: quoted-printable Message-Id: <4929EC39-0862-4547-B044-44C396529F74@FreeBSD.org> References: <201409291036.s8TAaFUs040310@svn.freebsd.org> To: Dimitry Andric X-Mailer: Apple Mail (2.1878.6) Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 29 Sep 2014 11:24:22 -0000 On 29 Sep 2014, at 11:10 , Dimitry Andric wrote: > On 29 Sep 2014, at 12:36, Bjoern A. Zeeb wrote: >> Author: bz >> Date: Mon Sep 29 10:36:14 2014 >> New Revision: 272281 >> URL: http://svnweb.freebsd.org/changeset/base/272281 >>=20 >> Log: >> Hopefully fix build breakage with gcc passing void * instead of char = * >> to "%s" format string after r272280. >>=20 >> PR: 83099 193927 >> MFC after: 3 days >> X-MFC with: r272280 >>=20 >> Modified: >> head/lib/libpam/modules/pam_login_access/pam_login_access.c >>=20 >> Modified: head/lib/libpam/modules/pam_login_access/pam_login_access.c >> = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >> --- head/lib/libpam/modules/pam_login_access/pam_login_access.c = Mon Sep 29 08:57:36 2014 (r272280) >> +++ head/lib/libpam/modules/pam_login_access/pam_login_access.c = Mon Sep 29 10:36:14 2014 (r272281) >> @@ -94,7 +94,8 @@ pam_sm_acct_mgmt(pam_handle_t *pamh, int >> PAM_VERBOSE_ERROR("%s is not allowed to log in on %s", >> user, tty); >> } else { >> - PAM_LOG("Checking login.access for user %s", user); >> + PAM_LOG("Checking login.access for user %s", >> + (const char *)user); >> if (login_access(user, "***unknown***") !=3D 0) >> return (PAM_SUCCESS); >> PAM_VERBOSE_ERROR("%s is not allowed to log in", user); >>=20 >=20 > Just a few lines after the one you fixed it accesses the same variable > again. Why doesn't it warn there? And why is 'user' not a char * to > begin with? :) For the latter ask des. the PAM_VERBOSE_ERROR goes into a function which (if remembering = correctly) does the va_start and asprintf rather than just being a macro = to printf. The arguments are not casted anywhere to that macro but I = am, again, sure des will have an opinion on it;-) =97=20 Bjoern A. Zeeb "Come on. Learn, goddamn it.", WarGames, 1983