1#include <thread>
2#include <fstream>
3
4int main(int argc, char *argv[])
5{
6 if (argc >= 2) {
7 std::ofstream(argv[1]).close();
8 }
9 // Wait to be attached.
10 std::this_thread::sleep_for(rtime: std::chrono::minutes(1));
11 return 0;
12}
13

source code of lldb/test/API/tools/lldb-server/attach-wait/main.cpp