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

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

/*
 * Copyright (c) 1980 Regents of the University of California.
 * All rights reserved.  The Berkeley software License Agreement
 * specifies the terms and conditions for redistribution.
 */

#ifndef lint
static char sccsid[] = "@(#)endwin.c	5.1 (Berkeley) 6/7/85";
#endif not lint

/*
 * Clean things up before exiting
 *
 */

# include	"curses.ext"

endwin()
{
	resetty();
	_puts(VE);
	_puts(TE);
	if (curscr) {
		if (curscr->_flags & _STANDOUT) {
			_puts(SE);
			curscr->_flags &= ~_STANDOUT;
		}
		_endwin = TRUE;
	}
}
