Skip to content

Commit

Permalink
ignore error for non UTF8 char
Browse files Browse the repository at this point in the history
  • Loading branch information
Julien committed Oct 10, 2023
1 parent f362ee7 commit 32a24ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion VeeamLogAnonymizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ def process_IP(input_file, output_file):
ip_pattern = r"\b\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}\b(?!])"

# Read the file
with open(input_file, 'r') as file:
with open(input_file, 'r', encoding='utf-8', errors='ignore') as file:
content = file.read()

# Find all IP addresses in the content using regex
Expand Down

0 comments on commit 32a24ae

Please sign in to comment.