This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug libstdc++/66803] std::this_thread::sleep_for gets interrupted by signals.


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=66803

--- Comment #3 from brootux at freenet dot de ---
workaround until fixed i.e. for 1 second:

auto wakeup_time = std::chrono::system_clock::now() + std::chrono::seconds(1);
while (std::chrono::system_clock::now() < wakeup_time) {
    std::this_thread::sleep_for(std::chrono::milliseconds(100));
}

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]