> From: Bruno Haible <br...@clisp.org> > Cc: gavinsmith0...@gmail.com, bug-texinfo@gnu.org > Date: Sun, 15 Oct 2023 15:11:33 +0200 > > Eli Zaretskii wrote: > > > For 'popen' and 'pclose', one needs the gnulib modules 'popen' and > > > 'pclose', > > > respectively. > > > > Windows has _popen and _pclose, which can be used instead. > > _popen uses text mode, not binary mode, by default, AFAIK. This can be > problematic.
_popen accepts a MODE argument which can be used to control that, see https://learn.microsoft.com/en-us/cpp/c-runtime-library/reference/popen-wpopen?view=msvc-170 We use this in the stand-alone Info reader, for example, in this snippet from info/filesys.c: stream = popen (command, FOPEN_RBIN);