提交 5a4fd268 编写于 作者: H Haojun Liao

other: merge 3.0

上级 0a37d464
...@@ -18,10 +18,6 @@ ...@@ -18,10 +18,6 @@
#include "os.h" #include "os.h"
#if defined(WINDOWS) #if defined(WINDOWS)
BOOL WINAPI CtrlHandler(DWORD fdwCtrlType) {
printf("\n" TAOS_CONSOLE_PROMPT_HEADER);
return TRUE;
}
#elif defined(_TD_DARWIN_64) #elif defined(_TD_DARWIN_64)
#else #else
#include <dlfcn.h> #include <dlfcn.h>
...@@ -128,7 +124,6 @@ int taosSetConsoleEcho(bool on) { ...@@ -128,7 +124,6 @@ int taosSetConsoleEcho(bool on) {
void taosSetTerminalMode() { void taosSetTerminalMode() {
#if defined(WINDOWS) #if defined(WINDOWS)
SetConsoleCtrlHandler(CtrlHandler, TRUE);
#else #else
struct termios newtio; struct termios newtio;
...@@ -179,7 +174,6 @@ int32_t taosGetOldTerminalMode() { ...@@ -179,7 +174,6 @@ int32_t taosGetOldTerminalMode() {
void taosResetTerminalMode() { void taosResetTerminalMode() {
#if defined(WINDOWS) #if defined(WINDOWS)
SetConsoleCtrlHandler(CtrlHandler, FALSE);
#else #else
if (tcsetattr(0, TCSANOW, &oldtio) != 0) { if (tcsetattr(0, TCSANOW, &oldtio) != 0) {
fprintf(stderr, "Fail to reset the terminal properties!\n"); fprintf(stderr, "Fail to reset the terminal properties!\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册