--- nono/debugger/console.cpp 2026/04/29 17:04:30 1.1.1.1 +++ nono/debugger/console.cpp 2026/04/29 17:04:56 1.1.1.3 @@ -1,6 +1,7 @@ // // nono -// Copyright (C) 2020 isaki@NetBSD.org +// Copyright (C) 2020 nono project +// Licensed under nono-license.txt // #include "console.h" @@ -151,8 +152,7 @@ Console::Gets_editline(std::string& buf) // ヒストリに記録 // の前に前後の空白は取り除いておく - std::string hbuf = string_ltrim(buf); - string_rtrim(hbuf); + std::string hbuf = string_trim(buf); // 空文字列でなければ、ヒストリに記録 if (!hbuf.empty()) { @@ -178,7 +178,7 @@ Console::Gets_normal(std::string& buf) // 入力チェック int -Console::Poll() +Console::Poll(int msec) { struct pollfd pfd; @@ -190,7 +190,7 @@ Console::Poll() pfd.fd = inp.fd; pfd.events = POLLIN; pfd.revents = 0; - int r = poll(&pfd, 1, 0); + int r = poll(&pfd, 1, msec); return r; }