X-Git-Url: http://ncurses.scripts.mit.edu/?a=blobdiff_plain;f=test%2Fdemo_new_pair.c;h=26256a80af161d1998a1400b2a056d5066cb21ec;hb=690589d8f19e38925db061296d4f704e4a965bb2;hp=8c29870b81290d25626603f9f44cf5e67ca90afa;hpb=af3d0ee323cbb22d2a7596d564bf68f7307f5076;p=ncurses.git diff --git a/test/demo_new_pair.c b/test/demo_new_pair.c index 8c29870b..26256a80 100644 --- a/test/demo_new_pair.c +++ b/test/demo_new_pair.c @@ -26,7 +26,7 @@ * authorization. * ****************************************************************************/ /* - * $Id: demo_new_pair.c,v 1.14 2017/06/17 19:48:45 tom Exp $ + * $Id: demo_new_pair.c,v 1.15 2017/06/26 00:20:23 tom Exp $ * * Demonstrate the alloc_pair() function. */ @@ -231,6 +231,7 @@ main(int argc, char *argv[]) } if (newterm(NULL, output, stdin) == 0) { fprintf(stderr, "Cannot initialize terminal\n"); + fclose(output); ExitProgram(EXIT_FAILURE); } (void) cbreak(); /* read chars without wait for \n */