]> git.baikalelectronics.ru Git - kernel.git/commit
tls: Fixed uninitialised vars warning
authorVakul Garg <vakul.garg@nxp.com>
Mon, 24 Sep 2018 10:39:49 +0000 (16:09 +0530)
committerDavid S. Miller <davem@davemloft.net>
Mon, 24 Sep 2018 19:24:52 +0000 (12:24 -0700)
commit1a9c14b8039a01eabcd2ca3d0351e6aa67f685f9
treeeff037f4f01dd804bbb808073658d184765d5b31
parentfc1318c94942984703edbb85ae37ecfebca1ab27
tls: Fixed uninitialised vars warning

In tls_sw_sendmsg() and tls_sw_sendpage(), it is possible that the
uninitialised variable 'ret' gets passed to sk_stream_error(). So
initialise local variable 'ret' to '0. The warnings were detected by
'smatch' tool.

Fixes: 4e09428b5ad7 ("net/tls: Add support for async encryption")
Signed-off-by: Vakul Garg <vakul.garg@nxp.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tls/tls_sw.c