Fix not properly resetting needle buffer in createTrieFromStoredDomainOpt()

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/1902

The cached needle didn't match the one stored in the
needle buffer when resetting the cached needle without
resetting the needle buffer.
This commit is contained in:
Raymond Hill 2021-12-25 07:51:12 -05:00
parent 7998eada5c
commit d66cd1116c
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
1 changed files with 2 additions and 1 deletions

View File

@ -266,7 +266,8 @@ class HNTrieContainer {
this.add(itrie);
}
}
this.needle = ''; // Important
this.needle = ''; // Important
this.buf[255] = 0; // Important
return itrie;
}