Better detect invalid network filter patterns

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/2566
This commit is contained in:
Raymond Hill 2023-03-30 12:58:19 -04:00
parent 1835e90125
commit 42a00ec742
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2
1 changed files with 2 additions and 2 deletions

View File

@ -1275,9 +1275,9 @@ export class AstFilterParser {
case NODE_TYPE_NET_OPTION_NAME_WEBRTC: case NODE_TYPE_NET_OPTION_NAME_WEBRTC:
realBad = true; realBad = true;
break; break;
case NODE_TYPE_NET_PATTERN: case NODE_TYPE_NET_PATTERN_RAW:
realBad = this.hasOptions() === false && realBad = this.hasOptions() === false &&
this.getNodeStringLen(targetNode) === 1; this.getNetPattern().length <= 1;
break; break;
default: default:
break; break;