Fix a copy-and-pasteo.

Fix the handling of the case of a "matches" operator with a field and a
character constant as operands.

Change-Id: I6451cee907d8486db96937173d0098de91ce7956
Reviewed-on: https://code.wireshark.org/review/18424
Reviewed-by: Guy Harris <guy@alum.mit.edu>
This commit is contained in:
Guy Harris 2016-10-24 01:15:59 -07:00
parent 681b97a047
commit c786aa56ad
1 changed files with 4 additions and 4 deletions

View File

@ -1115,11 +1115,11 @@ check_relation_LHS_RANGE(dfwork_t *dfw, const char *relation_string,
if (strcmp(relation_string, "matches") == 0) {
/* Convert to a FT_PCRE */
fvalue = dfilter_fvalue_from_unparsed(dfw, FT_PCRE, s, FALSE);
} else {
/* The RHS should be FT_BYTES, but a character is just a
* one-byte byte string. */
fvalue = charconst_to_bytes(dfw, s, allow_partial_value);
}
/* The RHS should be FT_BYTES, but a character is just a
* one-byte byte string. */
fvalue = charconst_to_bytes(dfw, s, allow_partial_value);
if (!fvalue) {
DebugLog((" 5 check_relation_LHS_RANGE(type2 = STTYPE_UNPARSED): Could not convert from string!\n"));
THROW(TypeError);