On 9/2/20 6:13 PM, Arkadiusz Hiler wrote:
> +/* ?attach@ifstream@@QAEXH@Z */
> +/* ?attach@ifstream@@QEAAXH@Z */
> +DEFINE_THISCALL_WRAPPER(ifstream_attach, 8)
> +void __thiscall ifstream_attach(istream *this, filedesc fd)
> +{
> +�� �� TRACE("(%p %d)\n", this, fd);
> +�� �� if (filebuf_attach(ifstream_rdbuf(this), fd) == NULL)
> +�� �� �� �� ios_clear(istream_get_ios(this), IOSTATE_failbit);
The function should add failbit flag to current state (it shouldn't e.g.
clear eof state). The same applies to all cases where failbit is set.
Thanks,
Piotr