search for: expr_f_interval_end

Displaying 1 result from an estimated 1 matches for "expr_f_interval_end".

2017 Sep 11
1
[Bug 1181] New: incorrect sort function at segtree.c
...urces is incorrect. static int expr_value_cmp(const void *p1, const void *p2) { struct expr *e1 = *(void * const *)p1; struct expr *e2 = *(void * const *)p2; int ret; ret = mpz_cmp(expr_value(e1)->value, expr_value(e2)->value); if (ret == 0 && (e1->flags & EXPR_F_INTERVAL_END)) return -1; else return 1; return ret; } as you can see, running never reaches "return ret" and basically it doesn't matter if mpz_cmp returned 1 or -1. Suggested solution: static int expr_value_cmp(const void *p1, const void *p2) { struct expr *e1 =...