projectm (2.0.1+dfsg-12) 20_fix-parser.patch

Summary

 src/libprojectM/MilkdropPresetFactory/Parser.cpp |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

    
download this patch

Patch contents

Description: Fix to parser in cases like 1.0-1.0-2.0
Forwarded: yes
Last-Update: 2011-12-20
--- a/src/libprojectM/MilkdropPresetFactory/Parser.cpp
+++ b/src/libprojectM/MilkdropPresetFactory/Parser.cpp
@@ -1013,7 +1013,7 @@
      of the item to be inserted is greater than the root's
      precedence, then make gen_expr the root */
 
-  if (infix_op->precedence > (*root)->infix_op->precedence)
+  if (infix_op->precedence >= (*root)->infix_op->precedence)
   {
     new_root = new TreeExpr(infix_op, NULL, *root, NULL);
     (*root) = new_root;