X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2Fporting.cpp;h=0adc955a94f77b28861a5bd8b4c00e118feeab09;hb=f97d4355beb79370d3bc69ea6baabb33ed90a8cd;hp=f349c0ce5e8c877660b7beab497145b57eee76a5;hpb=03db16d55b87908f2a08f9431162316d02e66233;p=minetest.git diff --git a/src/porting.cpp b/src/porting.cpp index f349c0ce5..0adc955a9 100644 --- a/src/porting.cpp +++ b/src/porting.cpp @@ -56,9 +56,10 @@ void sigint_handler(int sig) dstream< + #include + + BOOL WINAPI event_handler(DWORD sig) + { + switch(sig) + { + case CTRL_C_EVENT: + case CTRL_CLOSE_EVENT: + case CTRL_LOGOFF_EVENT: + case CTRL_SHUTDOWN_EVENT: + + if(g_killed == false) + { + dstream<