Testsuite problem
Benjamin Kosnik
bkoz@redhat.com
Fri Apr 16 18:43:00 GMT 2004
Hey Pétur.
>testsuite/27_io/basic_filebuf/close/char/9964.cc was supposed to check
>how basic_filebuf::close() behaves when a low level write fails, but
>with this change, the write is no longer failing:
>
> filebuf fb;
> sleep(1);
>- filebuf* ret = fb.open(name, ios_base::out | ios_base::trunc);
>+ filebuf* ret = fb.open(name, ios_base::in | ios_base::out);
> VERIFY( ret != NULL );
> VERIFY( fb.is_open() );
>
>@@ -67,7 +67,7 @@
> fb.sputc('a');
>
> ret = fb.close();
>- VERIFY( ret == NULL );
>+ VERIFY( ret != NULL );
> VERIFY( !fb.is_open() );
> }
Ouch. I didn't see this part of the patch when it went in.
>The solution is probably to just use ios_base::out, and XFAIL on those
>targets where that doesn't work.
Yep. If you prepare a patch, and post it, it'll be easier to track this
issue. We can sort this out after the release.
>There is no problem with the rest of the changes, in those tests the
>pipes are being used to make seek fail.
True. However, there are problems with some of the testsuite idioms
involving files. Zack commented on at the time, but nobody had/has time
to fix it at the moment.
Hopefully we'll be able to focus on this after 3.4.0.
best,
benjamin
More information about the Libstdc++
mailing list