Skip to content

Commit

Permalink
defaultdict for string_counts
Browse files Browse the repository at this point in the history
  • Loading branch information
ooprathamm committed Mar 8, 2024
1 parent 5d93bdd commit 275f597
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion floss/qs/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
import functools
import itertools
import contextlib
from collections import defaultdict
from typing import Set, Dict, List, Union, Tuple, Literal, Callable, Iterable, Optional, Sequence
from dataclasses import field, dataclass

Expand Down Expand Up @@ -651,7 +652,7 @@ def tag_strings(self, taggers: Sequence[Tagger]):
this can be overridden, if a subclass has more ways of tagging strings,
such as a PE file and code/reloc regions.
"""
string_counts = {}
string_counts = defaultdict(int)

tagged_strings: List[TaggedString] = []

Expand Down

0 comments on commit 275f597

Please sign in to comment.