Skip to content

Commit 84efbae

Browse files
ZackerySpytzmiss-islington
authored andcommitted
[2.7] bpo-9194: Fix the bounds checking in winreg.c's fixupMultiSZ() (GH-12687) (GH-12916)
(cherry picked from commit 56ed864) https://bugs.python.org/issue9194
1 parent 44a2c4a commit 84efbae

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

PC/_winreg.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -727,7 +727,7 @@ fixupMultiSZ(char **str, char *data, int len)
727727
Q = data + len;
728728
for (P = data, i = 0; P < Q && *P != '\0'; P++, i++) {
729729
str[i] = P;
730-
for(; *P != '\0'; P++)
730+
for (; P < Q && *P != '\0'; P++)
731731
;
732732
}
733733
}

0 commit comments

Comments
 (0)