linux(4): Properly allocate buffer for kern_getdirentries in readdir
authorDmitry Chagin <dchagin@FreeBSD.org>
Tue, 18 Jul 2023 21:44:15 +0000 (00:44 +0300)
committerDmitry Chagin <dchagin@FreeBSD.org>
Tue, 18 Jul 2023 21:44:15 +0000 (00:44 +0300)
commitfc1c787aa0157090e765ebba484e6e290e99f177
tree031affbbe84b01c87037644fa37b60ee35090f07
parent9efad6f9e1084e97dd6e2599562e7db0bd31a4ab
linux(4): Properly allocate buffer for kern_getdirentries in readdir

Looks like prior to ino64 project the size of the struct linux_dirent
was greater (or equal) to the size of the native struct dirent so the
native dirent fit into the buffer. After ino64 project the size of the
native struct dirent has increased.

Spotted by gcc12.
MFC after: 2 weeks
sys/compat/linux/linux_file.c