Код: Выделить всё
include
#include
#include
#include
#include
class SharedObject {
public:
std::string currentTime;
SharedObject() {
// Capture current time as string
auto now = std::chrono::system_clock::to_time_t(std::chrono::system_clock::now());
currentTime = std::ctime(&now); // Convert time to string
}
void displayTime() {
std::cout
Подробнее здесь: [url]https://stackoverflow.com/questions/79355900/strace-output-not-showing-malloc-and-free-system-call-in-a-multi-threaded-applic[/url]
Мобильная версия