aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/mate/mate_grammar.lemon
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2017-04-16 18:18:11 -0700
committerGuy Harris <guy@alum.mit.edu>2017-04-17 01:18:43 +0000
commitdae108837fc1d9c48eefbcc7feeff607c26e0a4e (patch)
treeaa2901323887c6e2b6ffaa1700ea72447527a832 /plugins/mate/mate_grammar.lemon
parent3f912df8754972a6db06eda36564a300d5a5e350 (diff)
Make the current MATE config pointer static only to packet-mate.c.
Pass it as an argument to everything else, so only packet-mate.c has the notion of there being *a* configuration, and everything else takes the configuration as an argument. Change-Id: Ia92c1539586d3e71580fd822cf07bd3d79a6f093 Reviewed-on: https://code.wireshark.org/review/21151 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'plugins/mate/mate_grammar.lemon')
-rw-r--r--plugins/mate/mate_grammar.lemon8
1 files changed, 4 insertions, 4 deletions
diff --git a/plugins/mate/mate_grammar.lemon b/plugins/mate/mate_grammar.lemon
index 5b0b6ca34e..c7e084230d 100644
--- a/plugins/mate/mate_grammar.lemon
+++ b/plugins/mate/mate_grammar.lemon
@@ -422,7 +422,7 @@ pdu_decl ::=
CLOSE_BRACE SEMICOLON.
{
- mate_cfg_pdu* cfg = new_pducfg(Name);
+ mate_cfg_pdu* cfg = new_pducfg(mc, Name);
extraction_t *extraction, *next_extraction;
GPtrArray* transport_stack = g_ptr_array_new();
int i;
@@ -458,7 +458,7 @@ pdu_decl ::=
for (extraction = Extraction; extraction; extraction = next_extraction) {
next_extraction = extraction->next;
- if ( ! add_hfid(extraction->hfi, extraction->as, cfg->hfids_attr) ) {
+ if ( ! add_hfid(mc, extraction->hfi, extraction->as, cfg->hfids_attr) ) {
configuration_error(mc,"MATE: failed to create extraction rule '%s'",extraction->as);
}
@@ -545,7 +545,7 @@ gop_decl(A) ::= GOP_KW NAME(Name) ON_KW pdu_name(PduName) MATCH_KW avpl(Key) OPE
if (g_hash_table_lookup(mc->gopcfgs,Name)) configuration_error(mc,"A Gop Named '%s' exists already.",Name);
if (g_hash_table_lookup(mc->gops_by_pduname,PduName) ) configuration_error(mc,"Gop for Pdu '%s' exists already",PduName);
- cfg = new_gopcfg(Name);
+ cfg = new_gopcfg(mc, Name);
g_hash_table_insert(mc->gops_by_pduname,PduName,cfg);
g_hash_table_insert(mc->gopcfgs,cfg->name,cfg);
@@ -632,7 +632,7 @@ gog_decl ::= GOG_KW NAME(Name) OPEN_BRACE
configuration_error(mc,"Gog '%s' exists already ",Name);
}
- cfg = new_gogcfg(Name);
+ cfg = new_gogcfg(mc, Name);
cfg->expiration = Expiration;
cfg->gop_tree_mode = Tree;