OpenAFS Master Repository branch, master, updated. BP--openafs-stable-1_6_x-1506-g342be35
Gerrit Code Review
gerrit@openafs.org
Wed, 10 Aug 2011 10:48:46 -0700 (PDT)
The following commit has been merged in the master branch:
commit 342be3535499c5ecd7d34b4edd43a4655559cb28
Author: Garrett Wollman <wollman@csail.mit.edu>
Date: Tue Aug 9 23:50:09 2011 -0400
stds.h: introduce AFS_NONNULL
AFS_NONNULL wraps the GCC/Clang function attribute __nonnull__, which
tells the compiler and the static analyzer that the pointer arguments
to a function (or specific ones, if provided) cannot be null. Note
that GCC has only limited support for warning about violations of these
constraints.
Usage examples:
int myfunc(struct foo *a, bar_t, struct baz *c) AFS_NONNULL((1));
tells the compiler that the first argument cannot be null (but the
third one can).
int myfunc2(struct foo *a, bar_t, struct baz *c) AFS_NONNULL();
tells the compiler that both pointer arguments cannot be null.
Change-Id: Id81f0c382a6a3bdd9bf9c716eb4091b433129d69
Suggested-by: Simon Wilkinson, comment on change Ic8751737 (#5180)
Reviewed-on: http://gerrit.openafs.org/5182
Reviewed-by: Simon Wilkinson <sxw@inf.ed.ac.uk>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementia.org>
src/config/stds.h | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
--
OpenAFS Master Repository