mirror of
https://github.com/python/cpython.git
synced 2025-11-03 11:23:31 +00:00
gh-108753: _Py_PrintSpecializationStats() uses Py_hexdigits (#109040)
This commit is contained in:
parent
f42edf1e7b
commit
fd5989bda1
1 changed files with 2 additions and 2 deletions
|
|
@ -290,8 +290,8 @@ _Py_PrintSpecializationStats(int to_file)
|
||||||
char hex_name[41];
|
char hex_name[41];
|
||||||
_PyOS_URandomNonblock(rand, 20);
|
_PyOS_URandomNonblock(rand, 20);
|
||||||
for (int i = 0; i < 20; i++) {
|
for (int i = 0; i < 20; i++) {
|
||||||
hex_name[2*i] = "0123456789abcdef"[rand[i]&15];
|
hex_name[2*i] = Py_hexdigits[rand[i]&15];
|
||||||
hex_name[2*i+1] = "0123456789abcdef"[(rand[i]>>4)&15];
|
hex_name[2*i+1] = Py_hexdigits[(rand[i]>>4)&15];
|
||||||
}
|
}
|
||||||
hex_name[40] = '\0';
|
hex_name[40] = '\0';
|
||||||
char buf[64];
|
char buf[64];
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue