提交 dafa39ad 编写于 作者: D Daniel P. Berrange

Remove unused ebtablesRemoveForwardPolicyReject method

The ebtablesRemoveForwardPolicyReject method was unused and
would not do anything useful even if called.
Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
上级 6e69008f
......@@ -210,35 +210,19 @@ ebtablesContextFree(ebtablesContext *ctx)
VIR_FREE(ctx);
}
static int
ebtablesForwardPolicyReject(ebtablesContext *ctx,
int action)
{
/* create it, if it does not exist */
if (action == ADD) {
ebtablesAddRemoveRule("--new-chain", ctx->chain, NULL,
NULL);
ebtablesAddRemoveRule("--insert", "FORWARD", "--jump",
ctx->chain, NULL);
}
return ebtablesAddRemoveRule("-P", ctx->chain, "DROP",
NULL);
}
int
ebtablesAddForwardPolicyReject(ebtablesContext *ctx)
{
return ebtablesForwardPolicyReject(ctx, ADD);
ebtablesAddRemoveRule("--new-chain", ctx->chain, NULL,
NULL);
ebtablesAddRemoveRule("--insert", "FORWARD", "--jump",
ctx->chain, NULL);
return ebtablesAddRemoveRule("-P", ctx->chain, "DROP",
NULL);
}
int
ebtablesRemoveForwardPolicyReject(ebtablesContext *ctx)
{
return ebtablesForwardPolicyReject(ctx, REMOVE);
}
/*
* Allow all traffic destined to the bridge, with a valid network address
*/
......
......@@ -42,6 +42,4 @@ int ebtablesRemoveForwardAllowIn (ebtablesContext *ctx,
int ebtablesAddForwardPolicyReject(ebtablesContext *ctx);
int ebtablesRemoveForwardPolicyReject(ebtablesContext *ctx);
#endif /* __QEMUD_ebtabLES_H__ */
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册