#include <stdio.h>

extern FILE *_firstfile;

int fflush(FILE *f)
{
    if(f){
        _flushbuf(f);
    }else{
        f=_firstfile;
        while(f){
            if(f->flags&_WRITE)_flushbuf(f);
            f=f->next;
        }
    }
    return(0);
}
