Joel “chesky” Salomon wrote:
I’ve got a function in the Brain-Dead SHell™ that I’m writing for
homework that looks like this:
        Biobuf in;

        void bdsh(int f) {
                Binit(&in, f, OREAD); yyparse(); Bterm(&in);
        }
This function gets called for each file named in argv[] after main()
open(2)s it.

My question is: is the call Bterm necessary, or will Binit
reinitialize the global Biobuf correctly on its own—or am I courting
trouble some other way?  The man page for bio(2) is a bit vauge on
reusing Biobufs.

What's one extra, correct, Bterm call among friends ?

Reply via email to