On Mon, 11 Nov 2024 at 17:41, Дмитрий Фролов <[email protected]> wrote: > Above loop dereferences the pointer env, which is pointing to > the memory area, which is not allowed to read.
* Not allowed to read environment variables? Is it because Debian/clang does not support the '**envp' parameter? Is '**envp' set to NULL on Debian? If '**envp' is not supported, then the compiler should throw an error at build time, no? > I am pointing on 2 facts: > 1. "env" is Microsoft`s extension, not a standard > 2. There is exact example, where standards violation raises > undefined behavior: debian13/clang16 > * If this is about Debian not supporting '**envp' parameter, then it'll help if the commit message says "...Debian does not support this non-standard extension and crashes QEMU". The asan error makes it sound like the patch fixes the use-after-free issue. What happens if the -lasan is not used? Does it still crash QEMUt? Thank you. --- - Prasad
