Always tag SRTP_PROTECTION_PROFILE and BIO_METHOD as const.
The BIO_METHODs ought to be const so they can go into rodata; BoringSSL makes BIO_new take a const BIO_METHOD *, so there's no need for it to be non-const. Also set SRTP_PROTECTION_PROFILE as const so we can constify those within BoringSSL (https://boringssl-review.googlesource.com/#/c/2720/) BUG=none R=henrike@webrtc.org Review URL: https://webrtc-codereview.appspot.com/34649004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@8013 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -74,7 +74,7 @@ static long socket_ctrl(BIO* h, int cmd, long arg1, void* arg2);
|
||||
static int socket_new(BIO* h);
|
||||
static int socket_free(BIO* data);
|
||||
|
||||
static BIO_METHOD methods_socket = {
|
||||
static const BIO_METHOD methods_socket = {
|
||||
BIO_TYPE_BIO,
|
||||
"socket",
|
||||
socket_write,
|
||||
@ -87,7 +87,7 @@ static BIO_METHOD methods_socket = {
|
||||
NULL,
|
||||
};
|
||||
|
||||
static BIO_METHOD* BIO_s_socket2() { return(&methods_socket); }
|
||||
static const BIO_METHOD* BIO_s_socket2() { return(&methods_socket); }
|
||||
|
||||
static BIO* BIO_new_socket(rtc::AsyncSocket* socket) {
|
||||
BIO* ret = BIO_new(BIO_s_socket2());
|
||||
|
||||
Reference in New Issue
Block a user