diff options
author | Michael Larson <slioch@slioch.vyatta.com> | 2010-05-20 15:40:39 -0700 |
---|---|---|
committer | Michael Larson <slioch@slioch.vyatta.com> | 2010-05-20 15:40:39 -0700 |
commit | 3daa8ab068b9f3e4548205d3bcd0ca4165d2197e (patch) | |
tree | 25edea2e7d78ac7cc35fd47839ee167ca2fa10fd /src | |
parent | 7fb9723429e0bed8690ba1cfa1b2af922496b96d (diff) | |
download | vyatta-cfg-3daa8ab068b9f3e4548205d3bcd0ca4165d2197e.tar.gz vyatta-cfg-3daa8ab068b9f3e4548205d3bcd0ca4165d2197e.zip |
fixed seg violation on commit due to extended multiple types support in valstruct.
Diffstat (limited to 'src')
-rw-r--r-- | src/cli_new.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/cli_new.c b/src/cli_new.c index 0684b71..c4d1b86 100644 --- a/src/cli_new.c +++ b/src/cli_new.c @@ -947,7 +947,11 @@ boolean val_cmp(const valstruct *left, const valstruct *right, vtw_cond_e cond) (void) sscanf(lval, format, left_parts, left_parts+1, left_parts+2, left_parts+3, left_parts+4, left_parts+5); - format = cond_formats[right->val_types[rcur]]; + + if ((rcur || right->cnt) + && right->val_types[rcur] != NULL) { + format = cond_formats[right->val_types[rcur]]; + } (void) sscanf(rval, format, right_parts, right_parts+1, right_parts+2, right_parts+3, right_parts+4, right_parts+5); |