Skip to content

Commit 5ef7945

Browse files
fix(fmtstr): String formatting
1 parent 0d0b351 commit 5ef7945

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pwnlib/fmtstr.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -889,7 +889,7 @@ def fmtstr_payload(offset, writes, numbwritten=0, write_size='byte', write_size_
889889
# Predict the size of bytes to substract.
890890
# We consider that the pattern ``START%XXX$pEND`` is always used.
891891
# This is because ``prefix`` got placed after ``payload``.
892-
search_pattern = "START%%d$pEND" % offset
892+
search_pattern = "START%%%d$pEND" % offset
893893
reverse_offset = len(search_pattern) + (len(search_pattern) % context.bytes)
894894
for _ in range(1000000):
895895
data_offset = (offset_bytes + len(fmt)) // context.bytes

0 commit comments

Comments
 (0)