summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYing Xue <ying.xue@windriver.com>2016-06-15 14:11:31 +0800
committerDavid S. Miller <davem@davemloft.net>2016-06-15 21:47:23 -0700
commitc91522f860bb9dd4178c8280bbebd4f4321b7199 (patch)
tree9b2f2fa943611fba8dde90320a3c1e3fe4081759
parent66d95b6705a6347f7b2645e042874ec0bb03b726 (diff)
tipc: eliminate uninitialized variable warning
net/tipc/link.c: In function ‘tipc_link_timeout’: net/tipc/link.c:744:28: warning: ‘mtyp’ may be used uninitialized in this function [-Wuninitialized] Fixes: 42b18f605fea ("tipc: refactor function tipc_link_timeout()") Acked-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--net/tipc/link.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/tipc/link.c b/net/tipc/link.c
index 7059c94f33c5..67b6ab9f4c8d 100644
--- a/net/tipc/link.c
+++ b/net/tipc/link.c
@@ -704,7 +704,8 @@ static void link_profile_stats(struct tipc_link *l)
*/
int tipc_link_timeout(struct tipc_link *l, struct sk_buff_head *xmitq)
{
- int mtyp, rc = 0;
+ int mtyp = 0;
+ int rc = 0;
bool state = false;
bool probe = false;
bool setup = false;