Skip to content

Commit

Permalink
Fix for greedy regular expressions causing improper header parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
campb303 committed Jan 19, 2021
1 parent c895ef1 commit 1e819d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/ECNQueue.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ def __parseHeaders(self) -> list:
# Example:
# [ce] QTime-Updated-By: campb303 becomes
# QTime-Updated-By: campb303
queuePrefixPattern = re.compile("\[.*\] {1}")
queuePrefixPattern = re.compile(r"\[.*?\] {1}")
for lineNumber in range(self.__getHeaderBoundary()):
line = self.__rawItem[lineNumber]
lineHasQueuePrefix = queuePrefixPattern.match(line)
Expand Down

0 comments on commit 1e819d8

Please sign in to comment.