From a2f625292aee0aba2c53b5091ab2c83bc1545c00 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:00:59 +0300 Subject: [PATCH 01/12] piterminal nonzero exit code on fail --- libs/console/piterminal.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libs/console/piterminal.cpp b/libs/console/piterminal.cpp index 795d9af3..768e37ae 100644 --- a/libs/console/piterminal.cpp +++ b/libs/console/piterminal.cpp @@ -880,7 +880,7 @@ bool PITerminal::initialize() { execvp(argv[0], argv); delete[] argv[0]; delete[] argv; - exit(0); + exit(127); } else { if (fr < 0 || PRIVATE->fd < 0) { piCoutObj << "forkpty error," << errorString(); -- 2.54.0 From b0307e8323cb64b4fd44a4fc96f4a1f5581dfe2e Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:01:36 +0300 Subject: [PATCH 02/12] fix piprocess set workdir --- libs/main/system/piprocess.cpp | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/libs/main/system/piprocess.cpp b/libs/main/system/piprocess.cpp index aa4c4713..ffa6a871 100644 --- a/libs/main/system/piprocess.cpp +++ b/libs/main/system/piprocess.cpp @@ -215,10 +215,10 @@ PRIVATE_DEFINITION_START(PIProcess) PeekNamedPipe(pipes[pipe_type][PipeRead], nullptr, 0, nullptr, &available, nullptr); if (available > 0) { BOOL ok = ReadFile(pipes[pipe_type][PipeRead], - read_buffer.data(offset), - piMini(available, read_buffer.size() - offset), - &bytes_read, - nullptr); + read_buffer.data(offset), + piMini(available, read_buffer.size() - offset), + &bytes_read, + nullptr); if (!ok) bytes_read = 0; } # else @@ -293,10 +293,10 @@ void PIProcess::startProc(bool detached) { si.dwFlags |= STARTF_USESTDHANDLES; const auto cmd = convertWindowsCmd(args); if (CreateProcessA(0, // No module name (use command line) - (LPSTR)cmd.data(), // Command line + (LPSTR)cmd.data(), // Command line 0, // Process handle not inheritable 0, // Thread handle not inheritable - true, // Set handle inheritance to FALSE + true, // Set handle inheritance to FALSE detached ? DETACHED_PROCESS /*CREATE_NEW_CONSOLE*/ : 0, // Creation flags 0, // Use environment wd.isEmpty() ? 0 : wd.data(), // Use working directory @@ -322,7 +322,7 @@ void PIProcess::startProc(bool detached) { if (!detached) PRIVATE->pid = pid_; if (pid_ == 0) { if (!wd.isEmpty()) { - if (!chdir(wd.data())) piCoutObj << "Error while set working directory"; + if (chdir(wd.data()) != 0) piCoutObj << "Error while set working directory"; } PRIVATE->closePipe(StdIn, PipeWrite); PRIVATE->closePipe(StdOut, PipeRead); -- 2.54.0 From 6f11eeb895a80827a2c5c51b9686038bfccb4663 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:02:35 +0300 Subject: [PATCH 03/12] check PIBinaryStream negative size to fix memory overflow --- libs/main/serialization/pibinarystream.h | 46 ++++++++++++++---------- 1 file changed, 28 insertions(+), 18 deletions(-) diff --git a/libs/main/serialization/pibinarystream.h b/libs/main/serialization/pibinarystream.h index 80dcbe25..0d4d1ab9 100644 --- a/libs/main/serialization/pibinarystream.h +++ b/libs/main/serialization/pibinarystream.h @@ -56,17 +56,17 @@ #else -# define BINARY_STREAM_FRIEND(T) \ - template \ - friend PIBinaryStream

& operator<<(PIBinaryStream

& s, const T & v); \ - template \ - friend PIBinaryStream

& operator>>(PIBinaryStream

& s, T & v); +# define BINARY_STREAM_FRIEND(T) \ + template \ + friend PIBinaryStream

& operator<<(PIBinaryStream

& s, const T & v); \ + template \ + friend PIBinaryStream

& operator>>(PIBinaryStream

& s, T & v); # define BINARY_STREAM_WRITE(T) \ - template \ - inline PIBinaryStream

& operator<<(PIBinaryStream

& s, const T & v) + template \ + inline PIBinaryStream

& operator<<(PIBinaryStream

& s, const T & v) # define BINARY_STREAM_READ(T) \ - template \ - inline PIBinaryStream

& operator>>(PIBinaryStream

& s, T & v) + template \ + inline PIBinaryStream

& operator>>(PIBinaryStream

& s, T & v) #endif @@ -410,7 +410,7 @@ template & operator>>(PIBinaryStream

& s, PIVector & v) { // piCout << ">> vector trivial default"; int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIVector<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -433,7 +433,7 @@ template & operator>>(PIBinaryStream

& s, PIVector & v) { // piCout << ">> vector trivial custom"; int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIVector<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -462,7 +462,7 @@ template & operator>>(PIBinaryStream

& s, PIDeque & v) { // piCout << ">> deque trivial default"; int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIDeque<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -485,7 +485,7 @@ template & operator>>(PIBinaryStream

& s, PIDeque & v) { // piCout << ">> deque trivial custom"; int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIDeque<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -516,7 +516,7 @@ inline PIBinaryStream

& operator>>(PIBinaryStream

& s, PIVector2D & v) int r, c; r = s.binaryStreamTakeInt(); c = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || r < 0 || c < 0) { fprintf(stderr, "error with PIVector2D<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -542,6 +542,11 @@ inline PIBinaryStream

& operator>>(PIBinaryStream

& s, PIVector2D & v) PIVector tmp; r = s.binaryStreamTakeInt(); c = s.binaryStreamTakeInt(); + if (s.wasReadError() || r < 0 || c < 0) { + fprintf(stderr, "error with PIVector2D<%s>\n", __PIP_TYPENAME__(T)); + v.clear(); + return s; + } s >> tmp; if (s.wasReadError()) { fprintf(stderr, "error with PIVector2D<%s>\n", __PIP_TYPENAME__(T)); @@ -618,7 +623,7 @@ template & operator>>(PIBinaryStream

& s, PIVector & v) { int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIVector<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -641,7 +646,7 @@ template & operator>>(PIBinaryStream

& s, PIDeque & v) { int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIDeque<%s>\n", __PIP_TYPENAME__(T)); v.clear(); return s; @@ -667,6 +672,11 @@ inline PIBinaryStream

& operator>>(PIBinaryStream

& s, PIVector2D & v) PIVector tmp; r = s.binaryStreamTakeInt(); c = s.binaryStreamTakeInt(); + if (s.wasReadError() || r < 0 || c < 0) { + fprintf(stderr, "error with PIVector2D<%s>\n", __PIP_TYPENAME__(T)); + v.clear(); + return s; + } s >> tmp; if (s.wasReadError()) { fprintf(stderr, "error with PIVector2D<%s>\n", __PIP_TYPENAME__(T)); @@ -700,7 +710,7 @@ template //! \~russian Восстанавливает ключи и значения %PIMap. inline PIBinaryStream

& operator>>(PIBinaryStream

& s, PIMap & v) { int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PIMap<%s, %s>\n", __PIP_TYPENAME__(Key), __PIP_TYPENAME__(T)); v.clear(); return s; @@ -749,7 +759,7 @@ template //! \~russian Восстанавливает ключи %PISet. inline PIBinaryStream

& operator>>(PIBinaryStream

& s, PISet & v) { int sz = s.binaryStreamTakeInt(); - if (s.wasReadError()) { + if (s.wasReadError() || sz < 0) { fprintf(stderr, "error with PISet<%s>\n", __PIP_TYPENAME__(Key)); v.clear(); return s; -- 2.54.0 From 9da2d4fdb34f5654989c17879a5e0295bdacc7fb Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:03:22 +0300 Subject: [PATCH 04/12] fix select usage --- libs/main/core/piwaitevent_p.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/libs/main/core/piwaitevent_p.cpp b/libs/main/core/piwaitevent_p.cpp index 3dff58bc..e816260c 100644 --- a/libs/main/core/piwaitevent_p.cpp +++ b/libs/main/core/piwaitevent_p.cpp @@ -89,12 +89,15 @@ bool PIWaitEvent::wait(int fd, CheckRole role) { FD_SET(pipe_fd[ReadEnd], &(fds[CheckRead])); FD_SET(fd, &(fds[CheckExeption])); if (fd_index != CheckExeption) FD_SET(fd, &(fds[fd_index])); - int sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); + int sr = -1; + do { + sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); + } while (sr < 0 && errno == EINTR); int buf = 0; while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) ; // piCout << "wait result" << sr << FD_ISSET(fd, &(fds[CheckExeption])) << FD_ISSET(fd, &(fds[fd_index])); - if (sr == EBADF || sr == EINTR) return false; + if (sr < 0) return false; if (FD_ISSET(fd, &(fds[CheckExeption]))) return true; return FD_ISSET(fd, &(fds[fd_index])); #endif -- 2.54.0 From c53f1d39aacdc00ea76836d3d5503ffcf5c0053f Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:03:56 +0300 Subject: [PATCH 05/12] fix piethernet blocking write return value --- libs/main/io_devices/piethernet.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/libs/main/io_devices/piethernet.cpp b/libs/main/io_devices/piethernet.cpp index 7cb7a1dc..16f8e24c 100644 --- a/libs/main/io_devices/piethernet.cpp +++ b/libs/main/io_devices/piethernet.cpp @@ -861,6 +861,7 @@ ssize_t PIEthernet::writeDevice(const void * data, ssize_t max_size) { return -1; } } + ret += sr; remain_data += sr; remain_size -= sr; } -- 2.54.0 From 11d6f7b0db53e8863cf73054e566d1080c4c8e8a Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:05:09 +0300 Subject: [PATCH 06/12] piethernet replace inet_ntoa by threadsafe inet_ntop --- libs/main/io_devices/piethernet.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libs/main/io_devices/piethernet.cpp b/libs/main/io_devices/piethernet.cpp index 16f8e24c..e4c086b0 100644 --- a/libs/main/io_devices/piethernet.cpp +++ b/libs/main/io_devices/piethernet.cpp @@ -102,7 +102,10 @@ #ifndef WINDOWS PIString getSockAddr(sockaddr * s) { - return s == 0 ? PIString() : PIStringAscii(inet_ntoa(((sockaddr_in *)s)->sin_addr)); + if (!s) return PIString(); + char buf[INET_ADDRSTRLEN]; + const char * r = inet_ntop(AF_INET, &((sockaddr_in *)s)->sin_addr, buf, sizeof(buf)); + return r ? PIStringAscii(r) : PIString(); } #endif -- 2.54.0 From dc69ebe5ae9dbc4a6ccf4e9789673196343bc80a Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:06:03 +0300 Subject: [PATCH 07/12] fix memleak in PIEthernet::interfaces for android --- libs/main/io_devices/piethernet.cpp | 27 ++++++++++++++++++--------- 1 file changed, 18 insertions(+), 9 deletions(-) diff --git a/libs/main/io_devices/piethernet.cpp b/libs/main/io_devices/piethernet.cpp index e4c086b0..024d3a03 100644 --- a/libs/main/io_devices/piethernet.cpp +++ b/libs/main/io_devices/piethernet.cpp @@ -1179,13 +1179,19 @@ PIEthernet::InterfaceList PIEthernet::interfaces() { # else # ifdef ANDROID struct ifconf ifc; - int s = ::socket(AF_INET, SOCK_STREAM, IPPROTO_IP); + int s = ::socket(AF_INET, SOCK_STREAM, IPPROTO_IP); + if (s == -1) { + piCout << "[PIEthernet]" + << "Can`t create socket: %1"_tr("PIEthernet").arg(errorString()); + return il; + } ifc.ifc_len = 256; ifc.ifc_buf = new char[ifc.ifc_len]; if (ioctl(s, SIOCGIFCONF, &ifc) < 0) { piCout << "[PIEthernet]" << "Can`t get interfaces: %1"_tr("PIEthernet").arg(errorString()); delete[] ifc.ifc_buf; + ::close(s); return il; } int icnt = ifc.ifc_len / sizeof(ifreq); @@ -1204,7 +1210,8 @@ PIEthernet::InterfaceList PIEthernet::interfaces() { if (ci.address == "127.0.0.1") ci.flags |= PIEthernet::ifLoopback; il << ci; } - delete ifc.ifc_buf; + delete[] ifc.ifc_buf; + ::close(s); # else struct ifaddrs *ret, *cif = 0; int s = ::socket(AF_INET, SOCK_STREAM, IPPROTO_IP); @@ -1295,8 +1302,10 @@ PINetworkAddress PIEthernet::interfaceAddress(const PIString & interface_) { piZeroMemory(ifr); strcpy(ifr.ifr_name, interface_.dataAscii()); int s = ::socket(AF_INET, SOCK_DGRAM, 0); - ioctl(s, SIOCGIFADDR, &ifr); - ::close(s); + if (s != -1) { + ioctl(s, SIOCGIFADDR, &ifr); + ::close(s); + } struct sockaddr_in * sa = (struct sockaddr_in *)&ifr.ifr_addr; return PINetworkAddress(uint(sa->sin_addr.s_addr)); #endif @@ -1417,13 +1426,13 @@ void PIEthernet::ethClosesocket(int sock, bool shutdown) { int PIEthernet::ethSetsockopt(int sock, int level, int optname, const void * optval, int optlen) { if (sock < 0) return -1; auto ret = setsockopt(sock, - level, - optname, + level, + optname, #ifdef WINDOWS - (char *) + (char *) #endif - optval, - optlen); + optval, + optlen); if (ret != 0) piCout << "setsockopt error:" << ethErrorString(); return ret; } -- 2.54.0 From ec989633474d84016e2b20a7141eb953ca9f7d1e Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:45:46 +0300 Subject: [PATCH 08/12] Revert "fix select usage" This reverts commit 9da2d4fdb34f5654989c17879a5e0295bdacc7fb. --- libs/main/core/piwaitevent_p.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/libs/main/core/piwaitevent_p.cpp b/libs/main/core/piwaitevent_p.cpp index e816260c..3dff58bc 100644 --- a/libs/main/core/piwaitevent_p.cpp +++ b/libs/main/core/piwaitevent_p.cpp @@ -89,15 +89,12 @@ bool PIWaitEvent::wait(int fd, CheckRole role) { FD_SET(pipe_fd[ReadEnd], &(fds[CheckRead])); FD_SET(fd, &(fds[CheckExeption])); if (fd_index != CheckExeption) FD_SET(fd, &(fds[fd_index])); - int sr = -1; - do { - sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); - } while (sr < 0 && errno == EINTR); + int sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); int buf = 0; while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) ; // piCout << "wait result" << sr << FD_ISSET(fd, &(fds[CheckExeption])) << FD_ISSET(fd, &(fds[fd_index])); - if (sr < 0) return false; + if (sr == EBADF || sr == EINTR) return false; if (FD_ISSET(fd, &(fds[CheckExeption]))) return true; return FD_ISSET(fd, &(fds[fd_index])); #endif -- 2.54.0 From 42dd5945dde307320359a494f91f7044638d5852 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:46:43 +0300 Subject: [PATCH 09/12] review fixes --- libs/console/piterminal.cpp | 2 +- libs/main/core/piwaitevent_p.cpp | 3 ++- libs/main/io_devices/piethernet.cpp | 1 + 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/libs/console/piterminal.cpp b/libs/console/piterminal.cpp index 768e37ae..aeaffd9a 100644 --- a/libs/console/piterminal.cpp +++ b/libs/console/piterminal.cpp @@ -880,7 +880,7 @@ bool PITerminal::initialize() { execvp(argv[0], argv); delete[] argv[0]; delete[] argv; - exit(127); + exit(errno); } else { if (fr < 0 || PRIVATE->fd < 0) { piCoutObj << "forkpty error," << errorString(); diff --git a/libs/main/core/piwaitevent_p.cpp b/libs/main/core/piwaitevent_p.cpp index 3dff58bc..2e07f073 100644 --- a/libs/main/core/piwaitevent_p.cpp +++ b/libs/main/core/piwaitevent_p.cpp @@ -94,7 +94,8 @@ bool PIWaitEvent::wait(int fd, CheckRole role) { while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) ; // piCout << "wait result" << sr << FD_ISSET(fd, &(fds[CheckExeption])) << FD_ISSET(fd, &(fds[fd_index])); - if (sr == EBADF || sr == EINTR) return false; + if (sr < 0) return false; + if (errno == EBADF || errno == EINTR) return false; if (FD_ISSET(fd, &(fds[CheckExeption]))) return true; return FD_ISSET(fd, &(fds[fd_index])); #endif diff --git a/libs/main/io_devices/piethernet.cpp b/libs/main/io_devices/piethernet.cpp index 024d3a03..a28da44f 100644 --- a/libs/main/io_devices/piethernet.cpp +++ b/libs/main/io_devices/piethernet.cpp @@ -104,6 +104,7 @@ PIString getSockAddr(sockaddr * s) { if (!s) return PIString(); char buf[INET_ADDRSTRLEN]; + memset(&buf, 0, INET_ADDRSTRLEN); const char * r = inet_ntop(AF_INET, &((sockaddr_in *)s)->sin_addr, buf, sizeof(buf)); return r ? PIStringAscii(r) : PIString(); } -- 2.54.0 From 427130e2cadfe349aca8d44b922979e8491f9a74 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:48:40 +0300 Subject: [PATCH 10/12] fix 2 --- libs/main/core/piwaitevent_p.cpp | 2 +- libs/main/io_devices/piethernet.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/libs/main/core/piwaitevent_p.cpp b/libs/main/core/piwaitevent_p.cpp index 2e07f073..dfb2b23c 100644 --- a/libs/main/core/piwaitevent_p.cpp +++ b/libs/main/core/piwaitevent_p.cpp @@ -90,11 +90,11 @@ bool PIWaitEvent::wait(int fd, CheckRole role) { FD_SET(fd, &(fds[CheckExeption])); if (fd_index != CheckExeption) FD_SET(fd, &(fds[fd_index])); int sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); + if (sr < 0) return false; int buf = 0; while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) ; // piCout << "wait result" << sr << FD_ISSET(fd, &(fds[CheckExeption])) << FD_ISSET(fd, &(fds[fd_index])); - if (sr < 0) return false; if (errno == EBADF || errno == EINTR) return false; if (FD_ISSET(fd, &(fds[CheckExeption]))) return true; return FD_ISSET(fd, &(fds[fd_index])); diff --git a/libs/main/io_devices/piethernet.cpp b/libs/main/io_devices/piethernet.cpp index a28da44f..ad4a08b3 100644 --- a/libs/main/io_devices/piethernet.cpp +++ b/libs/main/io_devices/piethernet.cpp @@ -104,7 +104,7 @@ PIString getSockAddr(sockaddr * s) { if (!s) return PIString(); char buf[INET_ADDRSTRLEN]; - memset(&buf, 0, INET_ADDRSTRLEN); + piZeroMemory(buf, sizeof(buf)); const char * r = inet_ntop(AF_INET, &((sockaddr_in *)s)->sin_addr, buf, sizeof(buf)); return r ? PIStringAscii(r) : PIString(); } -- 2.54.0 From 3603f6df130f2b4c127eed15bb351dedb2da8333 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 12:59:36 +0300 Subject: [PATCH 11/12] fix piwaitevent --- libs/main/core/piwaitevent_p.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/libs/main/core/piwaitevent_p.cpp b/libs/main/core/piwaitevent_p.cpp index dfb2b23c..47983a5d 100644 --- a/libs/main/core/piwaitevent_p.cpp +++ b/libs/main/core/piwaitevent_p.cpp @@ -89,11 +89,11 @@ bool PIWaitEvent::wait(int fd, CheckRole role) { FD_SET(pipe_fd[ReadEnd], &(fds[CheckRead])); FD_SET(fd, &(fds[CheckExeption])); if (fd_index != CheckExeption) FD_SET(fd, &(fds[fd_index])); - int sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); + int sr = ::select(nfds, &(fds[CheckRead]), &(fds[CheckWrite]), &(fds[CheckExeption]), nullptr); if (sr < 0) return false; + errorClear(); int buf = 0; - while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) - ; + while (::read(pipe_fd[ReadEnd], &buf, sizeof(buf)) > 0) {} // piCout << "wait result" << sr << FD_ISSET(fd, &(fds[CheckExeption])) << FD_ISSET(fd, &(fds[fd_index])); if (errno == EBADF || errno == EINTR) return false; if (FD_ISSET(fd, &(fds[CheckExeption]))) return true; -- 2.54.0 From df9356393122bb3835cefafdff6f95ac6eaec157 Mon Sep 17 00:00:00 2001 From: "andrey.bychkov" Date: Wed, 5 Aug 2026 13:11:27 +0300 Subject: [PATCH 12/12] version --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index d22b323d..102a42b6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,7 +6,7 @@ endif() project(PIP) set(PIP_MAJOR 5) set(PIP_MINOR 8) -set(PIP_REVISION 0) +set(PIP_REVISION 1) set(PIP_SUFFIX _beta) set(PIP_COMPANY SHS) set(PIP_DOMAIN org.SHS) -- 2.54.0