diff options
author | 2014-04-17 02:50:32 +0000 | |
---|---|---|
committer | 2014-04-17 02:50:32 +0000 | |
commit | 8a890fdf0511c32aacc469a43e7ec93fd714f20c (patch) | |
tree | a877488966b6f92e8dab6816388edfc805247328 | |
parent | remove the identity files from this manpage - ssh-agent doesn't deal (diff) | |
download | wireguard-openbsd-8a890fdf0511c32aacc469a43e7ec93fd714f20c.tar.xz wireguard-openbsd-8a890fdf0511c32aacc469a43e7ec93fd714f20c.zip |
tag some functions with bounded. idea and ok djm
-rw-r--r-- | lib/libcrypto/bio/bio.h | 9 | ||||
-rw-r--r-- | lib/libssl/src/crypto/bio/bio.h | 9 |
2 files changed, 12 insertions, 6 deletions
diff --git a/lib/libcrypto/bio/bio.h b/lib/libcrypto/bio/bio.h index b64fd44b122..ee0afb15533 100644 --- a/lib/libcrypto/bio/bio.h +++ b/lib/libcrypto/bio/bio.h @@ -629,9 +629,12 @@ BIO * BIO_new(BIO_METHOD *type); int BIO_set(BIO *a, BIO_METHOD *type); int BIO_free(BIO *a); void BIO_vfree(BIO *a); -int BIO_read(BIO *b, void *data, int len); -int BIO_gets(BIO *bp, char *buf, int size); -int BIO_write(BIO *b, const void *data, int len); +int BIO_read(BIO *b, void *data, int len) + __attribute__((__bounded__(__buffer__,2,3))); +int BIO_gets(BIO *bp, char *buf, int size) + __attribute__((__bounded__ (__string__,2,3))); +int BIO_write(BIO *b, const void *data, int len) + __attribute__((__bounded__(__buffer__,2,3))); int BIO_puts(BIO *bp, const char *buf); int BIO_indent(BIO *b, int indent, int max); long BIO_ctrl(BIO *bp, int cmd, long larg, void *parg); diff --git a/lib/libssl/src/crypto/bio/bio.h b/lib/libssl/src/crypto/bio/bio.h index b64fd44b122..ee0afb15533 100644 --- a/lib/libssl/src/crypto/bio/bio.h +++ b/lib/libssl/src/crypto/bio/bio.h @@ -629,9 +629,12 @@ BIO * BIO_new(BIO_METHOD *type); int BIO_set(BIO *a, BIO_METHOD *type); int BIO_free(BIO *a); void BIO_vfree(BIO *a); -int BIO_read(BIO *b, void *data, int len); -int BIO_gets(BIO *bp, char *buf, int size); -int BIO_write(BIO *b, const void *data, int len); +int BIO_read(BIO *b, void *data, int len) + __attribute__((__bounded__(__buffer__,2,3))); +int BIO_gets(BIO *bp, char *buf, int size) + __attribute__((__bounded__ (__string__,2,3))); +int BIO_write(BIO *b, const void *data, int len) + __attribute__((__bounded__(__buffer__,2,3))); int BIO_puts(BIO *bp, const char *buf); int BIO_indent(BIO *b, int indent, int max); long BIO_ctrl(BIO *bp, int cmd, long larg, void *parg); |