[linux] Tests: unpacking hostile archives, the atomic switch, health check and auto rollback (red: the code follows)
This commit is contained in:
@@ -47,7 +47,7 @@ pub fn hex(b: &[u8]) -> String {
|
||||
|
||||
/// Lowercase or uppercase hex to bytes.
|
||||
pub(crate) fn unhex(s: &str) -> Option<Vec<u8>> {
|
||||
if s.len() % 2 != 0 {
|
||||
if !s.len().is_multiple_of(2) {
|
||||
return None;
|
||||
}
|
||||
(0..s.len())
|
||||
|
||||
Reference in New Issue
Block a user