summaryrefslogtreecommitdiff
path: root/src/cli_new.c
diff options
context:
space:
mode:
authorMichael Larson <slioch@slioch.vyatta.com>2010-05-28 11:53:12 -0700
committerMichael Larson <slioch@slioch.vyatta.com>2010-05-28 11:53:12 -0700
commit8d97d73fbc1e1df51be6af761c4e2c9e412a40f7 (patch)
tree30716eb40272a5575317d0151de5f3eceac9a202 /src/cli_new.c
parente9646c434de70ca36708ad2565941fdfa16d3c94 (diff)
downloadvyatta-cfg-8d97d73fbc1e1df51be6af761c4e2c9e412a40f7.tar.gz
vyatta-cfg-8d97d73fbc1e1df51be6af761c4e2c9e412a40f7.zip
fix bad comparison in multiple-type check
Diffstat (limited to 'src/cli_new.c')
-rw-r--r--src/cli_new.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cli_new.c b/src/cli_new.c
index b2d6e1d..bfd2d8c 100644
--- a/src/cli_new.c
+++ b/src/cli_new.c
@@ -929,7 +929,7 @@ boolean val_cmp(const valstruct *left, const valstruct *right, vtw_cond_e cond)
//don't bother comparing if these are different types.
if ((rcur || right->cnt)
- && right->val_types[rcur] != NULL) {
+ && right->val_types[rcur] != ERROR_TYPE) {
if (right->val_types[rcur] != val_type) {
continue;
}
@@ -957,7 +957,7 @@ boolean val_cmp(const valstruct *left, const valstruct *right, vtw_cond_e cond)
left_parts+5);
if ((rcur || right->cnt)
- && right->val_types[rcur] != NULL) {
+ && right->val_types[rcur] != ERROR_TYPE) {
format = cond_formats[right->val_types[rcur]];
}
(void) sscanf(rval, format, right_parts, right_parts+1,