1
0
mirror of https://github.com/php/php-src.git synced 2026-04-06 15:43:13 +02:00

Fix format string mistake in accel_move_code_to_huge_pages()

inode is unsigned, so use %lu instead of %ld
This commit is contained in:
Niels Dossche
2023-02-25 19:49:47 +01:00
committed by David Carlier
parent df579adac7
commit eb7bb3430b

View File

@@ -3029,7 +3029,7 @@ static void accel_move_code_to_huge_pages(void)
int ret;
while (1) {
ret = fscanf(f, "%lx-%lx %4s %lx %9s %ld %s\n", &start, &end, perm, &offset, dev, &inode, name);
ret = fscanf(f, "%lx-%lx %4s %lx %9s %lu %s\n", &start, &end, perm, &offset, dev, &inode, name);
if (ret == 7) {
if (perm[0] == 'r' && perm[1] == '-' && perm[2] == 'x' && name[0] == '/') {
long unsigned int seg_start = ZEND_MM_ALIGNED_SIZE_EX(start, huge_page_size);