]> ncurses.scripts.mit.edu Git - ncurses.git/blobdiff - test/savescreen.c
ncurses 6.1 - patch 20191214
[ncurses.git] / test / savescreen.c
index d96089dab4a11bd53c537b99767984ae65c8f36f..8aa82eff3f7371b5ebe1aa2381b3fca401b0cd0e 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2007-2017,2018 Free Software Foundation, Inc.              *
+ * Copyright (c) 2007-2018,2019 Free Software Foundation, Inc.              *
  *                                                                          *
  * Permission is hereby granted, free of charge, to any person obtaining a  *
  * copy of this software and associated documentation files (the            *
@@ -26,7 +26,7 @@
  * authorization.                                                           *
  ****************************************************************************/
 /*
- * $Id: savescreen.c,v 1.54 2018/12/29 17:25:56 tom Exp $
+ * $Id: savescreen.c,v 1.56 2019/12/14 23:25:29 tom Exp $
  *
  * Demonstrate save/restore functions from the curses library.
  * Thomas Dickey - 2007/7/14
@@ -387,7 +387,7 @@ main(int argc, char *argv[])
                        while (col++ < cols) {
                            int color = (((r * (g_max + 1)) + g) * (b_max + 1)
                                         + b + MAX_ANSI);
-#if HAVE_INIT_EXTENDED_COLOR
+#if USE_EXTENDED_COLOR
                            init_extended_pair(pair, color, color);
 #else
                            init_pair(pair, color, color);
@@ -495,7 +495,7 @@ main(int argc, char *argv[])
            }
            move(0, 0);
        } else {
-           exit_curses();
+           stop_curses();
            fprintf(stderr, "Cannot open \"%s\"\n", fill_by);
            ExitProgram(EXIT_FAILURE);
        }
@@ -507,14 +507,14 @@ main(int argc, char *argv[])
         * Use the last file as the initial/current screen.
         */
        if (last < 0) {
-           exit_curses();
+           stop_curses();
            printf("No screen-dumps given\n");
            ExitProgram(EXIT_FAILURE);
        }
 
        which = last;
        if (load_screen(files[which]) == ERR) {
-           exit_curses();
+           stop_curses();
            printf("Cannot load screen-dump %s\n", files[which]);
            ExitProgram(EXIT_FAILURE);
        }