/*
 * 5799-WZQ (C) COPYRIGHT = NONE
 * LICENSED MATERIALS - PROPERTY OF IBM
 */
/* $Header:PCLOSE.c 12.0$ */
/* $ACIS:PCLOSE.c 12.0$ */
/* $Source: /ibm/acis/usr/src/usr.lib/libpc/RCS/PCLOSE.c,v $ */

#ifndef lint
static char *rcsid = "$Header:PCLOSE.c 12.0$";
#endif

/* Copyright (c) 1979 Regents of the University of California */

static char sccsid[] = "@(#)PCLOSE.c 1.6 1/21/83";

/*
 * Close all files associated with the topmost stack frame.
 */

#include "h00vars.h"
#include "libpc.h"

PCLOSE(level)

	struct iorec		*level;
{
	register struct iorec	*next;

	next = _fchain.fchain;
	while(next != FILNIL && next->flev <= level) {
		next = PFCLOSE(next, TRUE);
	}
	_fchain.fchain = next;
}
