- std::bad_alloc 崩溃。
这样的内存分配会导致内存耗尽
-
is simulating an image of size 640x480 with 3 bytes per pixel, resulting in an allocation of approximately 921,600 bytes (or around 900 KB) for each image.
-
The error you’re encountering (std::bad_alloc) typically occurs when memory allocation fails, which could indicate that:
-
Excessive memory allocation over time: If this fu