diff options
author | Marcel Moolenaar <marcel@FreeBSD.org> | 2009-02-01 01:50:09 +0000 |
---|---|---|
committer | Marcel Moolenaar <marcel@FreeBSD.org> | 2009-02-01 01:50:09 +0000 |
commit | 709a626613955b67dc1b9045d617dc16ad96d15c (patch) | |
tree | 1f2a01ba12a863c7bbda0c9ec3787b0e50ffd8bf /sys/geom/geom.h | |
parent | 84bcda5d6851a64d00243493527ca2f25b0599cc (diff) | |
download | src-709a626613955b67dc1b9045d617dc16ad96d15c.tar.gz src-709a626613955b67dc1b9045d617dc16ad96d15c.zip |
Constify val in g_handleattr() and str in g_handleattr_str().
This allows passing string constants to g_handleattr_str().
Notes
Notes:
svn path=/head/; revision=187973
Diffstat (limited to 'sys/geom/geom.h')
-rw-r--r-- | sys/geom/geom.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sys/geom/geom.h b/sys/geom/geom.h index 8bf9439ef19b..a916ec515713 100644 --- a/sys/geom/geom.h +++ b/sys/geom/geom.h @@ -227,10 +227,11 @@ void g_error_provider(struct g_provider *pp, int error); struct g_provider *g_provider_by_name(char const *arg); int g_getattr__(const char *attr, struct g_consumer *cp, void *var, int len); #define g_getattr(a, c, v) g_getattr__((a), (c), (v), sizeof *(v)) -int g_handleattr(struct bio *bp, const char *attribute, void *val, int len); +int g_handleattr(struct bio *bp, const char *attribute, const void *val, + int len); int g_handleattr_int(struct bio *bp, const char *attribute, int val); int g_handleattr_off_t(struct bio *bp, const char *attribute, off_t val); -int g_handleattr_str(struct bio *bp, const char *attribute, char *str); +int g_handleattr_str(struct bio *bp, const char *attribute, const char *str); struct g_consumer * g_new_consumer(struct g_geom *gp); struct g_geom * g_new_geomf(struct g_class *mp, const char *fmt, ...); struct g_provider * g_new_providerf(struct g_geom *gp, const char *fmt, ...); |