diff options
author | Pavel Machek <pavel@ucw.cz> | 1999-04-10 11:45:08 +0200 |
---|---|---|
committer | Pavel Machek <pavel@ucw.cz> | 1999-04-10 11:45:08 +0200 |
commit | 2db3b2887ea93c9946956a9a5ce5a06f0ef783c3 (patch) | |
tree | 230d0260a17b3b4b758bfa392f4b6fbcc8a2b921 /filter/filter.c | |
parent | 49ed70b48e3b66c4dd71315e842733d69204698e (diff) | |
download | bird-2db3b2887ea93c9946956a9a5ce5a06f0ef783c3.tar bird-2db3b2887ea93c9946956a9a5ce5a06f0ef783c3.zip |
Decrease number of warnings.
Diffstat (limited to 'filter/filter.c')
-rw-r--r-- | filter/filter.c | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/filter/filter.c b/filter/filter.c index eb40d3c..4f23d1f 100644 --- a/filter/filter.c +++ b/filter/filter.c @@ -36,9 +36,9 @@ struct f_inst *startup_func = NULL; if (x.type == T_RETURN) \ return x; -#define ONEARG ARG(v1, arg1) -#define TWOARGS ARG(v1, arg1) \ - ARG(v2, arg2) +#define ONEARG ARG(v1, a1.p) +#define TWOARGS ARG(v1, a1.p) \ + ARG(v2, a2.p) #define TWOARGS_C TWOARGS \ if (v1.type != v2.type) \ runtime( "Can not operate with values of incompatible types" ); @@ -113,8 +113,8 @@ interpret(struct f_inst *what) /* Set */ case 's': - ARG(v2, arg2); - sym = what->arg1; + ARG(v2, a2.p); + sym = what->a1.p; switch (res.type = v2.type) { case T_VOID: runtime( "Can not assign void values" ); case T_INT: @@ -126,12 +126,12 @@ interpret(struct f_inst *what) break; case 'c': - res.type = (int) what->arg1; - res.val.i = (int) what->arg2; + res.type = what->a1.i; + res.val.i = (int) what->a2.p; break; case 'i': - res.type = (int) what->arg1; - res.val.i = * ((int *) what->arg2); + res.type = what->a1.i; + res.val.i = * ((int *) what->a2.p); break; case 'p': ONEARG; @@ -147,7 +147,7 @@ interpret(struct f_inst *what) if (v1.type != T_BOOL) runtime( "If requires bool expression" ); if (v1.val.i) { - ARG(res,arg2); + ARG(res,a2.p); res.val.i = 0; } else res.val.i = 1; res.type = T_BOOL; @@ -159,7 +159,7 @@ interpret(struct f_inst *what) ONEARG; printf( "\n" ); - switch ((int) what->arg2) { + switch (what->a2.i) { case F_QUITBIRD: die( "Filter asked me to die" ); case F_ACCEPT: @@ -167,7 +167,7 @@ interpret(struct f_inst *what) case F_ERROR: case F_REJECT: res.type = T_RETURN; - res.val.i = (int) what->arg1; + res.val.i = what->a1.i; break; case F_NOP: break; |