浏览代码

Fix test if select result is not empty for select function returning empty string with result=0, res.len=0.

Michal Matyska 19 年之前
父节点
当前提交
270757bb54
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      route.c

+ 1 - 1
route.c

@@ -816,7 +816,7 @@ inline static int comp_select(int op, select_t* sel, int rtype, union exp_op* r,
 	if (ret > 0) return 0;
 
 	switch(op) {
-	case NO_OP: return 1;
+	case NO_OP: return (val.len>0);
 	case BINOR_OP:
 	case BINAND_OP:
 		ERR("Binary operators cannot be used with string selects\n");