Hi!
> > +static void cleanup(void)
> > +{
> > + SAFE_CLOSE(fd1);
> > + SAFE_UNLINK("testfile1");
>
> ^^ These shouldn't be safe macros. I noticed it too late.
And the close(fd1) should be done only if it was opened.
But otherwise the test looks much better after this patch.
--
Cyril Hrubis
chrubis@suse.cz