Remove unused ebtablesRemoveForwardPolicyReject method

The ebtablesRemoveForwardPolicyReject method was unused and
would not do anything useful even if called.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
Daniel P. Berrange 2014-03-07 17:07:33 +00:00
parent 6e69008f3e
commit dafa39adbc
2 changed files with 6 additions and 24 deletions

View File

@ -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
*/

View File

@ -42,6 +42,4 @@ int ebtablesRemoveForwardAllowIn (ebtablesContext *ctx,
int ebtablesAddForwardPolicyReject(ebtablesContext *ctx);
int ebtablesRemoveForwardPolicyReject(ebtablesContext *ctx);
#endif /* __QEMUD_ebtabLES_H__ */