From 0d895bca31a636fdd1bf68ab3f0551bbc2fd01f0 Mon Sep 17 00:00:00 2001 From: Albert Graef Date: Tue, 16 Jun 2015 13:46:14 +0200 Subject: [PATCH] map lhs variable to the first rather than the last occurrence on the rhs of a rule --- src/pair.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pair.c b/src/pair.c index 88f8cd8..8713ac7 100644 --- a/src/pair.c +++ b/src/pair.c @@ -1037,7 +1037,7 @@ int get_pair_mapping(char* config, PAIR* p, int n) j = get_pair_osc_arg_index(var, argnames, p->argc_in_path + p->argc,k++); if(j >=0 ) p->midi_map[i] = j; - while(j >=0 ) + while(j >=0 && p->osc_map[j] == -1) { p->osc_map[j] = i; //check for additional copies