aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/lwtrace/kill_action.cpp
blob: 2b74dc4587c9cf44ca1b6774f7a3a729b042aa81 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#include "kill_action.h"

#ifndef _win_
#include <sys/types.h>
#include <signal.h>
#endif

#include <stdlib.h>

using namespace NLWTrace;
using namespace NLWTrace::NPrivate;

bool TKillActionExecutor::DoExecute(TOrbit&, const TParams&) {
#ifdef _win_
    abort();
#else
    int r = kill(getpid(), SIGABRT);
    Y_VERIFY(r == 0, "kill failed");
    return true;
#endif
}