mirror of
https://github.com/schnaader/precomp-cpp
synced 2026-08-23 00:23:04 -04:00
Both brute and intense mode can be active
This commit is contained in:
parent
b63677c4d9
commit
b8dffbbba6
1 changed files with 4 additions and 4 deletions
|
|
@ -2284,12 +2284,12 @@ int def(FILE *source, FILE *dest, int level, int windowbits, int memlevel) {
|
|||
return Z_OK;
|
||||
}
|
||||
|
||||
// Brute mode detects everything that intense mode detects, so it makes no sense
|
||||
// having both active. But since both of them can have a level limit, two helper
|
||||
// functions make things easier to handle.
|
||||
// Brute mode detects a bit less than intense mode to avoid false positives
|
||||
// and slowdowns, so both can be active. Also, both of them can have a level
|
||||
// limit, so two helper functions make things easier to handle.
|
||||
|
||||
bool intense_mode_is_active() {
|
||||
if ((!intense_mode) || (brute_mode_is_active())) return false;
|
||||
if (!intense_mode) return false;
|
||||
if ((intense_mode_depth_limit == -1) || (recursion_depth <= intense_mode_depth_limit)) return true;
|
||||
|
||||
return false;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue