]> git.michaelhowe.org Git - packages/o/openafs.git/commit
DARWIN: Make crfree() an inline function
authorSimon Wilkinson <sxw@your-file-system.com>
Fri, 30 Mar 2012 18:09:36 +0000 (19:09 +0100)
committerStephan Wiesand <stephan.wiesand@desy.de>
Wed, 18 Dec 2013 15:32:20 +0000 (07:32 -0800)
commit931d1a8bea393ba3df69b163cb4d05c35f3c948e
tree6b6f72cff5c4493a5d3e3ba3638c0b8d7901697d
parente54a0902fb4ed09d955a2cb9c3d091da28b8f21a
DARWIN: Make crfree() an inline function

On Darwin 100, we have
   #define crfree(X) kauth_cred_unref(&X)
which expands in one place to
   kauth_cred_unref(&(afs_ucred_t *)avc->linkData)

clang warns about this in -Werror mode, because arguments to the
address-of operator must be lvalues.

To fix this make crfree an inline function, which will then let us do
the indirection required.

Reviewed-on: http://gerrit.openafs.org/7073
Reviewed-by: Derrick Brashear <shadow@dementix.org>
Tested-by: Derrick Brashear <shadow@dementix.org>
(cherry picked from commit 1d8937b860509fcaabb041bc14faf7aa3023f3c9)

Change-Id: I869caa41884c33e6376d664a745efb0f8aa761d0
Reviewed-on: http://gerrit.openafs.org/10548
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Stephan Wiesand <stephan.wiesand@desy.de>
src/afs/DARWIN/osi_machdep.h