提交 be7faf71 编写于 作者: W wangweidong 提交者: David S. Miller

rds: remove the unneed NULL checking

unregister_net_sysctl_table will check the ctl_table_header,
so remove the unneed checking
Signed-off-by: NWang Weidong <wangweidong1@huawei.com>
Signed-off-by: NDavid S. Miller <davem@davemloft.net>
上级 97e72829
...@@ -111,8 +111,7 @@ static struct ctl_table rds_iw_sysctl_table[] = { ...@@ -111,8 +111,7 @@ static struct ctl_table rds_iw_sysctl_table[] = {
void rds_iw_sysctl_exit(void) void rds_iw_sysctl_exit(void)
{ {
if (rds_iw_sysctl_hdr) unregister_net_sysctl_table(rds_iw_sysctl_hdr);
unregister_net_sysctl_table(rds_iw_sysctl_hdr);
} }
int rds_iw_sysctl_init(void) int rds_iw_sysctl_init(void)
......
...@@ -94,8 +94,7 @@ static struct ctl_table rds_sysctl_rds_table[] = { ...@@ -94,8 +94,7 @@ static struct ctl_table rds_sysctl_rds_table[] = {
void rds_sysctl_exit(void) void rds_sysctl_exit(void)
{ {
if (rds_sysctl_reg_table) unregister_net_sysctl_table(rds_sysctl_reg_table);
unregister_net_sysctl_table(rds_sysctl_reg_table);
} }
int rds_sysctl_init(void) int rds_sysctl_init(void)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册