设置 UNUSED,修复编译警告
This commit is contained in:
@@ -1033,14 +1033,14 @@ const char* ssl_stream_dump_info(struct ssl_stream *stream, char* buffer, size_t
|
||||
static void ssl_stream_set_cmsg_string(struct ssl_stream* stream, enum tfe_cmsg_tlv_type type, const char* value_str)
|
||||
{
|
||||
struct tfe_cmsg* cmsg=tfe_stream_get0_cmsg(stream->tcp_stream);
|
||||
int ret=tfe_cmsg_set(cmsg, type, (const unsigned char*)value_str, (uint16_t)strlen(value_str));
|
||||
UNUSED int ret=tfe_cmsg_set(cmsg, type, (const unsigned char*)value_str, (uint16_t)strlen(value_str));
|
||||
assert(ret==0);
|
||||
return;
|
||||
}
|
||||
static void ssl_stream_set_cmsg_integer(struct ssl_stream* stream, enum tfe_cmsg_tlv_type type, uint64_t value_int)
|
||||
{
|
||||
struct tfe_cmsg* cmsg=tfe_stream_get0_cmsg(stream->tcp_stream);
|
||||
int ret=tfe_cmsg_set(cmsg, type, (const unsigned char*)&value_int, (uint16_t)sizeof(value_int));
|
||||
UNUSED int ret=tfe_cmsg_set(cmsg, type, (const unsigned char*)&value_int, (uint16_t)sizeof(value_int));
|
||||
assert(ret==0);
|
||||
return;
|
||||
}
|
||||
@@ -1954,7 +1954,7 @@ void ssl_async_downstream_create(struct future * f, struct ssl_mgr * mgr, struct
|
||||
* with the older SSL_shutdown() semantics, not exposing WANT_READ/WRITE
|
||||
* may or may not work.
|
||||
*/
|
||||
static struct ssl_shutdown_ctx * ssl_shutdown_ctx_new(struct ssl_stream * s_stream, struct event_base * evbase)
|
||||
UNUSED static struct ssl_shutdown_ctx * ssl_shutdown_ctx_new(struct ssl_stream * s_stream, struct event_base * evbase)
|
||||
{
|
||||
struct ssl_shutdown_ctx * ctx = ALLOC(struct ssl_shutdown_ctx, 1);
|
||||
ctx->evbase = evbase;
|
||||
@@ -2094,7 +2094,7 @@ complete:
|
||||
*/
|
||||
void ssl_stream_free_and_close_fd(struct ssl_stream * s_stream, struct event_base * evbase, struct bufferevent * bev)
|
||||
{
|
||||
struct ssl_shutdown_ctx * sslshutctx = NULL;
|
||||
UNUSED struct ssl_shutdown_ctx * sslshutctx = NULL;
|
||||
evutil_socket_t fd=-1;
|
||||
fd=bufferevent_getfd(bev);
|
||||
assert(fd==s_stream->_do_not_use.fd);
|
||||
@@ -2189,7 +2189,7 @@ int ssl_stream_get_integer_opt(struct ssl_stream *upstream, enum SSL_STREAM_OPT
|
||||
{
|
||||
struct ssl_service_status* svc=&upstream->up_parts.svc_status;
|
||||
struct tfe_cmsg *cmsg=NULL;
|
||||
int ret=0;
|
||||
UNUSED int ret=0;
|
||||
uint16_t out_size=0;
|
||||
switch(opt_type)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user