diff options
author | Ben Pfaff <blp@nicira.com> | 2010-02-11 14:59:01 -0800 |
---|---|---|
committer | Ben Pfaff <blp@nicira.com> | 2010-02-12 13:55:46 -0800 |
commit | 5019f688d4e3117960503d57978ff2e0fb3771e0 (patch) | |
tree | 6a9e6018fa57afe1a6c2792e4f2f50326a9d7a73 /lib/ofpbuf.c | |
parent | 3b917492c68516f113fe3d02cb4ed9885fae6b4d (diff) |
ofpbuf: Mark ofpbuf_headroom(), ofpbuf_tailroom() parameters const.
Diffstat (limited to 'lib/ofpbuf.c')
-rw-r--r-- | lib/ofpbuf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/ofpbuf.c b/lib/ofpbuf.c index bb216791..fd01ea8d 100644 --- a/lib/ofpbuf.c +++ b/lib/ofpbuf.c @@ -103,7 +103,7 @@ ofpbuf_delete(struct ofpbuf *b) * commonly, the data in a ofpbuf is at its beginning, and thus the ofpbuf's * headroom is 0.) */ size_t -ofpbuf_headroom(struct ofpbuf *b) +ofpbuf_headroom(const struct ofpbuf *b) { return (char*)b->data - (char*)b->base; } @@ -111,7 +111,7 @@ ofpbuf_headroom(struct ofpbuf *b) /* Returns the number of bytes that may be appended to the tail end of ofpbuf * 'b' before the ofpbuf must be reallocated. */ size_t -ofpbuf_tailroom(struct ofpbuf *b) +ofpbuf_tailroom(const struct ofpbuf *b) { return (char*)ofpbuf_end(b) - (char*)ofpbuf_tail(b); } |