fix for poll() function where the _child_created value is only ever set when not compiling on windows so on windows it should be omitted (#56)

This commit is contained in:
Németh Ádám 2020-05-03 18:54:29 +02:00 committed by GitHub
parent f1a698b50e
commit 2f6bb248c6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1299,7 +1299,10 @@ inline int Popen::wait() noexcept(false)
inline int Popen::poll() noexcept(false)
{
int status;
#ifndef _MSC_VER
if (!child_created_) return -1; // TODO: ??
#endif
#ifdef _MSC_VER
int ret = WaitForSingleObject(process_handle_, 0);