diff options
author | Jiapeng Chong <jiapeng.chong@linux.alibaba.com> | 2021-04-27 12:28:22 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-04-27 23:15:19 +0200 |
commit | 3afef8c7aa2de3574021c848b5f7c62687e6b166 (patch) | |
tree | b6e44bfed5446fd14a8f70686ee8c4d69fbe4f8e /net | |
parent | rds: Remove redundant assignment to nr_sig (diff) | |
download | linux-3afef8c7aa2de3574021c848b5f7c62687e6b166.tar.xz linux-3afef8c7aa2de3574021c848b5f7c62687e6b166.zip |
net/tls: Remove redundant initialization of record
record is being initialized to ctx->open_record but this is never
read as record is overwritten later on. Remove the redundant
initialization.
Cleans up the following clang-analyzer warning:
net/tls/tls_device.c:421:26: warning: Value stored to 'record' during
its initialization is never read [clang-analyzer-deadcode.DeadStores].
Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/tls/tls_device.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/tls/tls_device.c b/net/tls/tls_device.c index 790c6b7ecb26..76a6f8c2eec4 100644 --- a/net/tls/tls_device.c +++ b/net/tls/tls_device.c @@ -418,7 +418,7 @@ static int tls_push_data(struct sock *sk, struct tls_context *tls_ctx = tls_get_ctx(sk); struct tls_prot_info *prot = &tls_ctx->prot_info; struct tls_offload_context_tx *ctx = tls_offload_ctx_tx(tls_ctx); - struct tls_record_info *record = ctx->open_record; + struct tls_record_info *record; int tls_push_record_flags; struct page_frag *pfrag; size_t orig_size = size; |