aboutsummaryrefslogtreecommitdiffstats
path: root/nihav-registry/src/detect.rs
diff options
context:
space:
mode:
authorKostya Shishkov <kostya.shishkov@gmail.com>2023-02-17 18:23:38 +0100
committerKostya Shishkov <kostya.shishkov@gmail.com>2023-02-17 18:23:38 +0100
commit405cec9eed5d7f58440ec8495f5cbc1f5c6fee40 (patch)
treea115c0efc0cf1d50e54590dcb1663fec4a9751c4 /nihav-registry/src/detect.rs
parentf638a5b1b3241b3433689983aca22d9e6518a64f (diff)
downloadnihav-405cec9eed5d7f58440ec8495f5cbc1f5c6fee40.tar.gz
rename "str" variable to avoid confusion with the primitive type
Diffstat (limited to 'nihav-registry/src/detect.rs')
-rw-r--r--nihav-registry/src/detect.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/nihav-registry/src/detect.rs b/nihav-registry/src/detect.rs
index bb452b2..3c5a60a 100644
--- a/nihav-registry/src/detect.rs
+++ b/nihav-registry/src/detect.rs
@@ -176,11 +176,11 @@ impl<'a> CC<'a> {
CC::Le(ref arg) => { arg.le(src) },
CC::Gt(ref arg) => { arg.gt(src) },
CC::Ge(ref arg) => { arg.ge(src) },
- CC::Str(str) => {
- let mut val: Vec<u8> = vec![0; str.len()];
+ CC::Str(strng) => {
+ let mut val: Vec<u8> = vec![0; strng.len()];
let res = src.peek_buf(val.as_mut_slice());
if res.is_err() { return false; }
- val == str
+ val == strng
}
}
}