]> ncurses.scripts.mit.edu Git - ncurses.git/commitdiff
ncurses 5.9 - patch 20111022
authorThomas E. Dickey <dickey@invisible-island.net>
Sun, 23 Oct 2011 01:04:18 +0000 (01:04 +0000)
committerThomas E. Dickey <dickey@invisible-island.net>
Sun, 23 Oct 2011 01:04:18 +0000 (01:04 +0000)
+ correct logic for discarding mouse events, retaining the partial
  events used to build up click, double-click, etc, until needed
  (cf: 20110917).
+ fix configure script to avoid creating unused Ada95 makefile when
  gnat does not work.
+ cleanup width-related gcc 3.4.3 warnings for 64-bit platform, for the
  internal functions of libncurses.  The external interface of courses
  uses bool, which still produces these warnings.

56 files changed:
Ada95/aclocal.m4
Ada95/configure
Ada95/configure.in
NEWS
aclocal.m4
configure
configure.in
dist.mk
include/nc_alloc.h
ncurses/base/keybound.c
ncurses/base/keyok.c
ncurses/base/lib_addch.c
ncurses/base/lib_color.c
ncurses/base/lib_freeall.c
ncurses/base/lib_getch.c
ncurses/base/lib_getstr.c
ncurses/base/lib_instr.c
ncurses/base/lib_mouse.c
ncurses/base/lib_scanw.c
ncurses/base/lib_screen.c
ncurses/base/lib_scroll.c
ncurses/base/lib_set_term.c
ncurses/base/lib_slkset.c
ncurses/curses.priv.h
ncurses/tinfo/MKcaptab.sh
ncurses/tinfo/alloc_entry.c
ncurses/tinfo/captoinfo.c
ncurses/tinfo/comp_error.c
ncurses/tinfo/comp_parse.c
ncurses/tinfo/comp_scan.c
ncurses/tinfo/entries.c
ncurses/tinfo/lib_options.c
ncurses/tinfo/lib_print.c
ncurses/tinfo/lib_setup.c
ncurses/tinfo/lib_termcap.c
ncurses/tinfo/lib_tparm.c
ncurses/tinfo/lib_tputs.c
ncurses/tinfo/make_keys.c
ncurses/tinfo/read_entry.c
ncurses/tinfo/setbuf.c
ncurses/tinfo/tinfo_driver.c
ncurses/tinfo/write_entry.c
ncurses/trace/lib_trace.c
ncurses/trace/lib_traceatr.c
ncurses/trace/trace_buf.c
ncurses/trace/visbuf.c
ncurses/tty/hashmap.c
ncurses/tty/lib_mvcur.c
ncurses/tty/lib_tstp.c
ncurses/tty/lib_twait.c
ncurses/tty/tty_update.c
ncurses/widechar/lib_cchar.c
ncurses/widechar/lib_get_wstr.c
ncurses/widechar/lib_ins_wch.c
ncurses/widechar/lib_slk_wset.c
ncurses/widechar/lib_unget_wch.c

index 573c3b6d9484b8372059ae10ed83ec5e294cc01b..355d4371ccedc1a6f96a4e7ff5759c4a4a0ba1e3 100644 (file)
@@ -28,7 +28,7 @@ dnl***************************************************************************
 dnl
 dnl Author: Thomas E. Dickey
 dnl
-dnl $Id: aclocal.m4,v 1.37 2011/09/10 21:36:41 tom Exp $
+dnl $Id: aclocal.m4,v 1.38 2011/10/22 19:04:02 tom Exp $
 dnl Macros used in NCURSES Ada95 auto-configuration script.
 dnl
 dnl These macros are maintained separately from NCURSES.  The copyright on
@@ -2819,7 +2819,7 @@ AC_SUBST(PROG_EXT)
 test -n "$PROG_EXT" && AC_DEFINE_UNQUOTED(PROG_EXT,"$PROG_EXT")
 ])dnl
 dnl ---------------------------------------------------------------------------
-dnl CF_PROG_GNAT version: 1 updated: 2010/06/19 15:22:18
+dnl CF_PROG_GNAT version: 2 updated: 2011/10/22 14:01:47
 dnl ------------
 dnl Check for gnatmake, ensure that it is complete.
 AC_DEFUN([CF_PROG_GNAT],[
@@ -2827,6 +2827,7 @@ cf_ada_make=gnatmake
 AC_CHECK_PROG(gnat_exists, $cf_ada_make, yes, no)
 if test "$ac_cv_prog_gnat_exists" = no; then
    cf_ada_make=
+   cf_cv_prog_gnat_correct=no
 else
    CF_GNAT_VERSION
    AC_CHECK_PROG(M4_exists, m4, yes, no)
index bb3104def2d054dda3b29ae9d22930e511b9ed5c..f745a42b0c872ff88528e7d4bc4fff7b7f8b71e8 100644 (file)
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Revision: 1.35 .
+# From configure.in Revision: 1.36 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by Autoconf 2.52.20101002.
 #
@@ -10950,12 +10950,13 @@ if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
        CXXFLAGS=`echo ${CXXFLAGS} | sed -e 's%-g %%' -e 's%-g$%%'`
 fi
 
+cf_with_ada=yes
 if test "$cf_with_ada" != "no" ; then
 
 cf_ada_make=gnatmake
 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
 set dummy $cf_ada_make; ac_word=$2
-echo "$as_me:10958: checking for $ac_word" >&5
+echo "$as_me:10959: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
 if test "${ac_cv_prog_gnat_exists+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -10970,7 +10971,7 @@ for ac_dir in $ac_dummy; do
   test -z "$ac_dir" && ac_dir=.
   $as_executable_p "$ac_dir/$ac_word" || continue
 ac_cv_prog_gnat_exists="yes"
-echo "$as_me:10973: found $ac_dir/$ac_word" >&5
+echo "$as_me:10974: found $ac_dir/$ac_word" >&5
 break
 done
 
 fi
 gnat_exists=$ac_cv_prog_gnat_exists
 if test -n "$gnat_exists"; then
-  echo "$as_me:10982: result: $gnat_exists" >&5
+  echo "$as_me:10983: result: $gnat_exists" >&5
 echo "${ECHO_T}$gnat_exists" >&6
 else
-  echo "$as_me:10985: result: no" >&5
+  echo "$as_me:10986: result: no" >&5
 echo "${ECHO_T}no" >&6
 fi
 
 if test "$ac_cv_prog_gnat_exists" = no; then
    cf_ada_make=
+   cf_cv_prog_gnat_correct=no
 else
 
-echo "$as_me:10993: checking for gnat version" >&5
+echo "$as_me:10995: checking for gnat version" >&5
 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
        grep '[0-9].[0-9][0-9]*' |\
     sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
-echo "$as_me:10998: result: $cf_gnat_version" >&5
+echo "$as_me:11000: result: $cf_gnat_version" >&5
 echo "${ECHO_T}$cf_gnat_version" >&6
 
 case $cf_gnat_version in #(vi
@@ -11003,7 +11005,7 @@ case $cf_gnat_version in #(vi
        cf_cv_prog_gnat_correct=yes
        ;;
 *)
-       { echo "$as_me:11006: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
+       { echo "$as_me:11008: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
        cf_cv_prog_gnat_correct=no
        ;;
@@ -11011,7 +11013,7 @@ esac
 
    # Extract the first word of "m4", so it can be a program name with args.
 set dummy m4; ac_word=$2
-echo "$as_me:11014: checking for $ac_word" >&5
+echo "$as_me:11016: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
 if test "${ac_cv_prog_M4_exists+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -11026,7 +11028,7 @@ for ac_dir in $ac_dummy; do
   test -z "$ac_dir" && ac_dir=.
   $as_executable_p "$ac_dir/$ac_word" || continue
 ac_cv_prog_M4_exists="yes"
-echo "$as_me:11029: found $ac_dir/$ac_word" >&5
+echo "$as_me:11031: found $ac_dir/$ac_word" >&5
 break
 done
 
 fi
 M4_exists=$ac_cv_prog_M4_exists
 if test -n "$M4_exists"; then
-  echo "$as_me:11038: result: $M4_exists" >&5
+  echo "$as_me:11040: result: $M4_exists" >&5
 echo "${ECHO_T}$M4_exists" >&6
 else
-  echo "$as_me:11041: result: no" >&5
+  echo "$as_me:11043: result: no" >&5
 echo "${ECHO_T}no" >&6
 fi
 
@@ -11047,7 +11049,7 @@ fi
       echo Ada95 binding required program m4 not found. Ada95 binding disabled.
    fi
    if test "$cf_cv_prog_gnat_correct" = yes; then
-      echo "$as_me:11050: checking if GNAT works" >&5
+      echo "$as_me:11052: checking if GNAT works" >&5
 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
 
 rm -rf conftest* *~conftest*
@@ -11075,7 +11077,7 @@ else
 fi
 rm -rf conftest* *~conftest*
 
-      echo "$as_me:11078: result: $cf_cv_prog_gnat_correct" >&5
+      echo "$as_me:11080: result: $cf_cv_prog_gnat_correct" >&5
 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
    fi
 fi
@@ -11098,7 +11100,7 @@ fi
                        ;;
                esac
 
-echo "$as_me:11101: checking if GNAT supports generics" >&5
+echo "$as_me:11103: checking if GNAT supports generics" >&5
 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
 case $cf_gnat_version in #(vi
 3.[1-9]*|[4-9].*) #(vi
@@ -11108,7 +11110,7 @@ case $cf_gnat_version in #(vi
        cf_gnat_generics=no
        ;;
 esac
-echo "$as_me:11111: result: $cf_gnat_generics" >&5
+echo "$as_me:11113: result: $cf_gnat_generics" >&5
 echo "${ECHO_T}$cf_gnat_generics" >&6
 
 if test "$cf_gnat_generics" = yes
@@ -11120,7 +11122,7 @@ else
        cf_generic_objects=
 fi
 
-echo "$as_me:11123: checking if GNAT supports SIGINT" >&5
+echo "$as_me:11125: checking if GNAT supports SIGINT" >&5
 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
 if test "${cf_cv_gnat_sigint+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -11168,7 +11170,7 @@ fi
 rm -rf conftest* *~conftest*
 
 fi
-echo "$as_me:11171: result: $cf_cv_gnat_sigint" >&5
+echo "$as_me:11173: result: $cf_cv_gnat_sigint" >&5
 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
 
 if test $cf_cv_gnat_sigint = yes ; then
@@ -11177,7 +11179,7 @@ else
        USE_GNAT_SIGINT="#"
 fi
 
-echo "$as_me:11180: checking if GNAT pragma Unreferenced works" >&5
+echo "$as_me:11182: checking if GNAT pragma Unreferenced works" >&5
 echo $ECHO_N "checking if GNAT pragma Unreferenced works... $ECHO_C" >&6
 if test "${cf_cv_pragma_unreferenced+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -11208,7 +11210,7 @@ fi
 rm -rf conftest* *~conftest*
 
 fi
-echo "$as_me:11211: result: $cf_cv_pragma_unreferenced" >&5
+echo "$as_me:11213: result: $cf_cv_pragma_unreferenced" >&5
 echo "${ECHO_T}$cf_cv_pragma_unreferenced" >&6
 
 # if the pragma is supported, use it (needed in the Trace code).
@@ -11221,7 +11223,7 @@ fi
 cf_gnat_libraries=no
 cf_gnat_projects=no
 
-echo "$as_me:11224: checking if GNAT supports project files" >&5
+echo "$as_me:11226: checking if GNAT supports project files" >&5
 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
 case $cf_gnat_version in #(vi
 3.[0-9]*) #(vi
@@ -11289,14 +11291,14 @@ CF_EOF
        esac
        ;;
 esac
-echo "$as_me:11292: result: $cf_gnat_projects" >&5
+echo "$as_me:11294: result: $cf_gnat_projects" >&5
 echo "${ECHO_T}$cf_gnat_projects" >&6
 
 if test $cf_gnat_projects = yes
 then
-       echo "$as_me:11297: checking if GNAT supports libraries" >&5
+       echo "$as_me:11299: checking if GNAT supports libraries" >&5
 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
-       echo "$as_me:11299: result: $cf_gnat_libraries" >&5
+       echo "$as_me:11301: result: $cf_gnat_libraries" >&5
 echo "${ECHO_T}$cf_gnat_libraries" >&6
 fi
 
@@ -11316,7 +11318,7 @@ else
        USE_GNAT_LIBRARIES="#"
 fi
 
-echo "$as_me:11319: checking for ada-compiler" >&5
+echo "$as_me:11321: checking for ada-compiler" >&5
 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
 
 # Check whether --with-ada-compiler or --without-ada-compiler was given.
@@ -11327,12 +11329,12 @@ else
   cf_ada_compiler=gnatmake
 fi;
 
-echo "$as_me:11330: result: $cf_ada_compiler" >&5
+echo "$as_me:11332: result: $cf_ada_compiler" >&5
 echo "${ECHO_T}$cf_ada_compiler" >&6
 
                cf_ada_package=terminal_interface
 
-echo "$as_me:11335: checking for ada-include" >&5
+echo "$as_me:11337: checking for ada-include" >&5
 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
 
 # Check whether --with-ada-include or --without-ada-include was given.
@@ -11368,7 +11370,7 @@ case ".$withval" in #(vi
   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
   ;;
 *)
-  { { echo "$as_me:11371: error: expected a pathname, not \"$withval\"" >&5
+  { { echo "$as_me:11373: error: expected a pathname, not \"$withval\"" >&5
 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    { (exit 1); exit 1; }; }
   ;;
@@ -11377,10 +11379,10 @@ esac
 fi
 ADA_INCLUDE="$withval"
 
-echo "$as_me:11380: result: $ADA_INCLUDE" >&5
+echo "$as_me:11382: result: $ADA_INCLUDE" >&5
 echo "${ECHO_T}$ADA_INCLUDE" >&6
 
-echo "$as_me:11383: checking for ada-objects" >&5
+echo "$as_me:11385: checking for ada-objects" >&5
 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
 
 # Check whether --with-ada-objects or --without-ada-objects was given.
@@ -11416,7 +11418,7 @@ case ".$withval" in #(vi
   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
   ;;
 *)
-  { { echo "$as_me:11419: error: expected a pathname, not \"$withval\"" >&5
+  { { echo "$as_me:11421: error: expected a pathname, not \"$withval\"" >&5
 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    { (exit 1); exit 1; }; }
   ;;
@@ -11425,10 +11427,10 @@ esac
 fi
 ADA_OBJECTS="$withval"
 
-echo "$as_me:11428: result: $ADA_OBJECTS" >&5
+echo "$as_me:11430: result: $ADA_OBJECTS" >&5
 echo "${ECHO_T}$ADA_OBJECTS" >&6
 
-echo "$as_me:11431: checking if an Ada95 shared-library should be built" >&5
+echo "$as_me:11433: checking if an Ada95 shared-library should be built" >&5
 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
 
 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
@@ -11438,7 +11440,7 @@ if test "${with_ada_sharedlib+set}" = set; then
 else
   with_ada_sharedlib=no
 fi;
-echo "$as_me:11441: result: $with_ada_sharedlib" >&5
+echo "$as_me:11443: result: $with_ada_sharedlib" >&5
 echo "${ECHO_T}$with_ada_sharedlib" >&6
 
 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
@@ -11454,12 +11456,12 @@ then
 fi
 
        else
-               { { echo "$as_me:11457: error: No usable Ada compiler found" >&5
+               { { echo "$as_me:11459: error: No usable Ada compiler found" >&5
 echo "$as_me: error: No usable Ada compiler found" >&2;}
    { (exit 1); exit 1; }; }
        fi
 else
-       { { echo "$as_me:11462: error: The Ada compiler is needed for this package" >&5
+       { { echo "$as_me:11464: error: The Ada compiler is needed for this package" >&5
 echo "$as_me: error: The Ada compiler is needed for this package" >&2;}
    { (exit 1); exit 1; }; }
 fi
@@ -11506,7 +11508,7 @@ elif test "$includedir" != "/usr/include"; then
 fi
 
 ### Build up pieces for makefile rules
-echo "$as_me:11509: checking default library suffix" >&5
+echo "$as_me:11511: checking default library suffix" >&5
 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in
@@ -11517,10 +11519,10 @@ echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
        shared)  DFT_ARG_SUFFIX=''   ;;
        esac
        test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
-echo "$as_me:11520: result: $DFT_ARG_SUFFIX" >&5
+echo "$as_me:11522: result: $DFT_ARG_SUFFIX" >&5
 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
 
-echo "$as_me:11523: checking default library-dependency suffix" >&5
+echo "$as_me:11525: checking default library-dependency suffix" >&5
 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in #(vi
@@ -11573,10 +11575,10 @@ echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
        esac
        test -n "$LIB_SUFFIX" && DFT_LIB_SUFFIX="${LIB_SUFFIX}${DFT_LIB_SUFFIX}"
        test -n "$LIB_SUFFIX" && DFT_DEP_SUFFIX="${LIB_SUFFIX}${DFT_DEP_SUFFIX}"
-echo "$as_me:11576: result: $DFT_DEP_SUFFIX" >&5
+echo "$as_me:11578: result: $DFT_DEP_SUFFIX" >&5
 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
 
-echo "$as_me:11579: checking default object directory" >&5
+echo "$as_me:11581: checking default object directory" >&5
 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in
@@ -11592,7 +11594,7 @@ echo $ECHO_N "checking default object directory... $ECHO_C" >&6
                        DFT_OBJ_SUBDIR='obj_s' ;;
                esac
        esac
-echo "$as_me:11595: result: $DFT_OBJ_SUBDIR" >&5
+echo "$as_me:11597: result: $DFT_OBJ_SUBDIR" >&5
 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
 
 ### Set up low-level terminfo dependencies for makefiles.
@@ -11808,7 +11810,7 @@ DEFS=-DHAVE_CONFIG_H
 : ${CONFIG_STATUS=./config.status}
 ac_clean_files_save=$ac_clean_files
 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:11811: creating $CONFIG_STATUS" >&5
+{ echo "$as_me:11813: creating $CONFIG_STATUS" >&5
 echo "$as_me: creating $CONFIG_STATUS" >&6;}
 cat >$CONFIG_STATUS <<_ACEOF
 #! $SHELL
@@ -11984,7 +11986,7 @@ cat >>$CONFIG_STATUS <<\EOF
     echo "$ac_cs_version"; exit 0 ;;
   --he | --h)
     # Conflict between --help and --header
-    { { echo "$as_me:11987: error: ambiguous option: $1
+    { { echo "$as_me:11989: error: ambiguous option: $1
 Try \`$0 --help' for more information." >&5
 echo "$as_me: error: ambiguous option: $1
 Try \`$0 --help' for more information." >&2;}
@@ -12003,7 +12005,7 @@ Try \`$0 --help' for more information." >&2;}
     ac_need_defaults=false;;
 
   # This is an error.
-  -*) { { echo "$as_me:12006: error: unrecognized option: $1
+  -*) { { echo "$as_me:12008: error: unrecognized option: $1
 Try \`$0 --help' for more information." >&5
 echo "$as_me: error: unrecognized option: $1
 Try \`$0 --help' for more information." >&2;}
@@ -12074,7 +12076,7 @@ do
   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
   "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
-  *) { { echo "$as_me:12077: error: invalid argument: $ac_config_target" >&5
+  *) { { echo "$as_me:12079: error: invalid argument: $ac_config_target" >&5
 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
    { (exit 1); exit 1; }; };;
   esac
@@ -12391,7 +12393,7 @@ done; }
   esac
 
   if test x"$ac_file" != x-; then
-    { echo "$as_me:12394: creating $ac_file" >&5
+    { echo "$as_me:12396: creating $ac_file" >&5
 echo "$as_me: creating $ac_file" >&6;}
     rm -f "$ac_file"
   fi
@@ -12409,7 +12411,7 @@ echo "$as_me: creating $ac_file" >&6;}
       -) echo $tmp/stdin ;;
       [\\/$]*)
          # Absolute (can't be DOS-style, as IFS=:)
-         test -f "$f" || { { echo "$as_me:12412: error: cannot find input file: $f" >&5
+         test -f "$f" || { { echo "$as_me:12414: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          echo $f;;
@@ -12422,7 +12424,7 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
            echo $srcdir/$f
          else
            # /dev/null tree
-           { { echo "$as_me:12425: error: cannot find input file: $f" >&5
+           { { echo "$as_me:12427: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          fi;;
@@ -12488,7 +12490,7 @@ for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
   * )   ac_file_in=$ac_file.in ;;
   esac
 
-  test x"$ac_file" != x- && { echo "$as_me:12491: creating $ac_file" >&5
+  test x"$ac_file" != x- && { echo "$as_me:12493: creating $ac_file" >&5
 echo "$as_me: creating $ac_file" >&6;}
 
   # First look for the input files in the build tree, otherwise in the
@@ -12499,7 +12501,7 @@ echo "$as_me: creating $ac_file" >&6;}
       -) echo $tmp/stdin ;;
       [\\/$]*)
          # Absolute (can't be DOS-style, as IFS=:)
-         test -f "$f" || { { echo "$as_me:12502: error: cannot find input file: $f" >&5
+         test -f "$f" || { { echo "$as_me:12504: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          echo $f;;
@@ -12512,7 +12514,7 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
            echo $srcdir/$f
          else
            # /dev/null tree
-           { { echo "$as_me:12515: error: cannot find input file: $f" >&5
+           { { echo "$as_me:12517: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          fi;;
@@ -12570,7 +12572,7 @@ cat >>$CONFIG_STATUS <<\EOF
   rm -f $tmp/in
   if test x"$ac_file" != x-; then
     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
-      { echo "$as_me:12573: $ac_file is unchanged" >&5
+      { echo "$as_me:12575: $ac_file is unchanged" >&5
 echo "$as_me: $ac_file is unchanged" >&6;}
     else
       ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
index 6c5480f3812409634ceef99130585400fb0f27f2..a1efc7835fe640b35b23a6ac991cb92c65b2dbd6 100644 (file)
@@ -28,14 +28,14 @@ dnl***************************************************************************
 dnl
 dnl Author: Thomas E. Dickey
 dnl
-dnl $Id: configure.in,v 1.35 2011/09/24 15:32:32 tom Exp $
+dnl $Id: configure.in,v 1.36 2011/10/22 19:02:53 tom Exp $
 dnl Process this file with autoconf to produce a configure script.
 dnl
 dnl See http://invisible-island.net/autoconf/ for additional information.
 dnl
 dnl ---------------------------------------------------------------------------
 AC_PREREQ(2.13.20020210)
-AC_REVISION($Revision: 1.35 $)
+AC_REVISION($Revision: 1.36 $)
 AC_INIT(gen/gen.c)
 AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
 
@@ -492,7 +492,7 @@ if test -z "$cf_user_CFLAGS" && test "$with_no_leaks" = no ; then
 fi
 
 CF_HELP_MESSAGE(Ada95 Binding Options:)
-
+cf_with_ada=yes
 dnl Check for availability of GNU Ada Translator (GNAT).
 dnl At the moment we support no other Ada95 compiler.
 if test "$cf_with_ada" != "no" ; then
diff --git a/NEWS b/NEWS
index b4087abb957b6f8a63a31784edaacbd579384e91..4b27cf61fb749a98882f765432a8e18fe2d29c9f 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -25,7 +25,7 @@
 -- sale, use or other dealings in this Software without prior written        --
 -- authorization.                                                            --
 -------------------------------------------------------------------------------
--- $Id: NEWS,v 1.1800 2011/10/15 23:34:06 tom Exp $
+-- $Id: NEWS,v 1.1804 2011/10/22 23:06:29 tom Exp $
 -------------------------------------------------------------------------------
 
 This is a log of changes that ncurses has gone through since Zeyd started
@@ -45,6 +45,16 @@ See the AUTHORS file for the corresponding full names.
 Changes through 1.9.9e did not credit all contributions;
 it is not possible to add this information.
 
+20111022
+       + correct logic for discarding mouse events, retaining the partial
+         events used to build up click, double-click, etc, until needed
+         (cf: 20110917).
+       + fix configure script to avoid creating unused Ada95 makefile when
+         gnat does not work.
+       + cleanup width-related gcc 3.4.3 warnings for 64-bit platform, for the
+         internal functions of libncurses.  The external interface of courses
+         uses bool, which still produces these warnings.
+
 20111015
        + improve description of --disable-tic-depends option to make it
          clear that it may be useful whether or not the --with-termlib
@@ -85,7 +95,7 @@ it is not possible to add this information.
          TINFO_ARGS into pieces corresponding to LDFLAGS and LIBS variables,
          to help separate searches for tic- and tinfo-libraries (patch by Nick
          Alcock aka "Nix").
-       + build-fix for lib_mouse.c changes (ch: 20110917).
+       + build-fix for lib_mouse.c changes (cf: 20110917).
 
 20110917
        + fix compiler warning for clang 2.9
index 457b52440c03401155f82433bdd98c22d2744d44..46ba5e7b0780a144238281417b7fc0a021ce1023 100644 (file)
@@ -28,7 +28,7 @@ dnl***************************************************************************
 dnl
 dnl Author: Thomas E. Dickey 1995-on
 dnl
-dnl $Id: aclocal.m4,v 1.575 2011/09/24 16:55:29 tom Exp $
+dnl $Id: aclocal.m4,v 1.577 2011/10/22 18:58:44 tom Exp $
 dnl Macros used in NCURSES auto-configuration script.
 dnl
 dnl These macros are maintained separately from NCURSES.  The copyright on
@@ -4794,7 +4794,7 @@ AC_SUBST(PROG_EXT)
 test -n "$PROG_EXT" && AC_DEFINE_UNQUOTED(PROG_EXT,"$PROG_EXT")
 ])dnl
 dnl ---------------------------------------------------------------------------
-dnl CF_PROG_GNAT version: 1 updated: 2010/06/19 15:22:18
+dnl CF_PROG_GNAT version: 2 updated: 2011/10/22 14:01:47
 dnl ------------
 dnl Check for gnatmake, ensure that it is complete.
 AC_DEFUN([CF_PROG_GNAT],[
@@ -4802,6 +4802,7 @@ cf_ada_make=gnatmake
 AC_CHECK_PROG(gnat_exists, $cf_ada_make, yes, no)
 if test "$ac_cv_prog_gnat_exists" = no; then
    cf_ada_make=
+   cf_cv_prog_gnat_correct=no
 else
    CF_GNAT_VERSION
    AC_CHECK_PROG(M4_exists, m4, yes, no)
@@ -5625,7 +5626,7 @@ if test "$cf_cv_sizechange" != no ; then
 fi
 ])dnl
 dnl ---------------------------------------------------------------------------
-dnl CF_SRC_MODULES version: 21 updated: 2010/09/04 17:37:40
+dnl CF_SRC_MODULES version: 22 updated: 2011/10/22 14:58:07
 dnl --------------
 dnl For each parameter, test if the source-directory exists, and if it contains
 dnl a 'modules' file.  If so, add to the list $cf_cv_src_modules which we'll
@@ -5716,7 +5717,7 @@ test -z "$MAKE_TERMINFO" && SRC_SUBDIRS="$SRC_SUBDIRS misc"
 test "$cf_with_cxx_binding" != no && SRC_SUBDIRS="$SRC_SUBDIRS c++"
 
 ADA_SUBDIRS=
-if test "$cf_cv_prog_gnat_correct" = yes && test -f $srcdir/Ada95/Makefile.in; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = xyes && test -f $srcdir/Ada95/Makefile.in; then
        SRC_SUBDIRS="$SRC_SUBDIRS Ada95"
        ADA_SUBDIRS="gen src"
        if test "x$cf_with_tests" != "xno" ; then
index b617edc8d91046cf285fb8718d590c8c4c55b9d5..34025444656c759c80dd1e41d05e83e505057996 100755 (executable)
--- a/configure
+++ b/configure
@@ -1,5 +1,5 @@
 #! /bin/sh
-# From configure.in Revision: 1.526 .
+# From configure.in Revision: 1.527 .
 # Guess values for system-dependent variables and create Makefiles.
 # Generated by Autoconf 2.52.20101002.
 #
 
 if test "$ac_cv_prog_gnat_exists" = no; then
    cf_ada_make=
+   cf_cv_prog_gnat_correct=no
 else
 
-echo "$as_me:18407: checking for gnat version" >&5
+echo "$as_me:18408: checking for gnat version" >&5
 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
 cf_gnat_version=`${cf_ada_make:-gnatmake} -v 2>&1 | \
        grep '[0-9].[0-9][0-9]*' |\
     sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
-echo "$as_me:18412: result: $cf_gnat_version" >&5
+echo "$as_me:18413: result: $cf_gnat_version" >&5
 echo "${ECHO_T}$cf_gnat_version" >&6
 
 case $cf_gnat_version in #(vi
@@ -18417,7 +18418,7 @@ case $cf_gnat_version in #(vi
        cf_cv_prog_gnat_correct=yes
        ;;
 *)
-       { echo "$as_me:18420: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
+       { echo "$as_me:18421: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&5
 echo "$as_me: WARNING: Unsupported GNAT version $cf_gnat_version. We require 3.11 or better. Disabling Ada95 binding." >&2;}
        cf_cv_prog_gnat_correct=no
        ;;
@@ -18425,7 +18426,7 @@ esac
 
    # Extract the first word of "m4", so it can be a program name with args.
 set dummy m4; ac_word=$2
-echo "$as_me:18428: checking for $ac_word" >&5
+echo "$as_me:18429: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
 if test "${ac_cv_prog_M4_exists+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -18440,7 +18441,7 @@ for ac_dir in $ac_dummy; do
   test -z "$ac_dir" && ac_dir=.
   $as_executable_p "$ac_dir/$ac_word" || continue
 ac_cv_prog_M4_exists="yes"
-echo "$as_me:18443: found $ac_dir/$ac_word" >&5
+echo "$as_me:18444: found $ac_dir/$ac_word" >&5
 break
 done
 
 fi
 M4_exists=$ac_cv_prog_M4_exists
 if test -n "$M4_exists"; then
-  echo "$as_me:18452: result: $M4_exists" >&5
+  echo "$as_me:18453: result: $M4_exists" >&5
 echo "${ECHO_T}$M4_exists" >&6
 else
-  echo "$as_me:18455: result: no" >&5
+  echo "$as_me:18456: result: no" >&5
 echo "${ECHO_T}no" >&6
 fi
 
@@ -18461,7 +18462,7 @@ fi
       echo Ada95 binding required program m4 not found. Ada95 binding disabled.
    fi
    if test "$cf_cv_prog_gnat_correct" = yes; then
-      echo "$as_me:18464: checking if GNAT works" >&5
+      echo "$as_me:18465: checking if GNAT works" >&5
 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
 
 rm -rf conftest* *~conftest*
@@ -18489,7 +18490,7 @@ else
 fi
 rm -rf conftest* *~conftest*
 
-      echo "$as_me:18492: result: $cf_cv_prog_gnat_correct" >&5
+      echo "$as_me:18493: result: $cf_cv_prog_gnat_correct" >&5
 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
    fi
 fi
@@ -18514,7 +18515,7 @@ fi
                                ;;
                        esac
 
-echo "$as_me:18517: checking if GNAT supports generics" >&5
+echo "$as_me:18518: checking if GNAT supports generics" >&5
 echo $ECHO_N "checking if GNAT supports generics... $ECHO_C" >&6
 case $cf_gnat_version in #(vi
 3.[1-9]*|[4-9].*) #(vi
@@ -18524,7 +18525,7 @@ case $cf_gnat_version in #(vi
        cf_gnat_generics=no
        ;;
 esac
-echo "$as_me:18527: result: $cf_gnat_generics" >&5
+echo "$as_me:18528: result: $cf_gnat_generics" >&5
 echo "${ECHO_T}$cf_gnat_generics" >&6
 
 if test "$cf_gnat_generics" = yes
@@ -18536,7 +18537,7 @@ else
        cf_generic_objects=
 fi
 
-echo "$as_me:18539: checking if GNAT supports SIGINT" >&5
+echo "$as_me:18540: checking if GNAT supports SIGINT" >&5
 echo $ECHO_N "checking if GNAT supports SIGINT... $ECHO_C" >&6
 if test "${cf_cv_gnat_sigint+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -18584,7 +18585,7 @@ fi
 rm -rf conftest* *~conftest*
 
 fi
-echo "$as_me:18587: result: $cf_cv_gnat_sigint" >&5
+echo "$as_me:18588: result: $cf_cv_gnat_sigint" >&5
 echo "${ECHO_T}$cf_cv_gnat_sigint" >&6
 
 if test $cf_cv_gnat_sigint = yes ; then
@@ -18593,7 +18594,7 @@ else
        USE_GNAT_SIGINT="#"
 fi
 
-echo "$as_me:18596: checking if GNAT pragma Unreferenced works" >&5
+echo "$as_me:18597: checking if GNAT pragma Unreferenced works" >&5
 echo $ECHO_N "checking if GNAT pragma Unreferenced works... $ECHO_C" >&6
 if test "${cf_cv_pragma_unreferenced+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -18624,7 +18625,7 @@ fi
 rm -rf conftest* *~conftest*
 
 fi
-echo "$as_me:18627: result: $cf_cv_pragma_unreferenced" >&5
+echo "$as_me:18628: result: $cf_cv_pragma_unreferenced" >&5
 echo "${ECHO_T}$cf_cv_pragma_unreferenced" >&6
 
 # if the pragma is supported, use it (needed in the Trace code).
@@ -18637,7 +18638,7 @@ fi
 cf_gnat_libraries=no
 cf_gnat_projects=no
 
-echo "$as_me:18640: checking if GNAT supports project files" >&5
+echo "$as_me:18641: checking if GNAT supports project files" >&5
 echo $ECHO_N "checking if GNAT supports project files... $ECHO_C" >&6
 case $cf_gnat_version in #(vi
 3.[0-9]*) #(vi
@@ -18705,14 +18706,14 @@ CF_EOF
        esac
        ;;
 esac
-echo "$as_me:18708: result: $cf_gnat_projects" >&5
+echo "$as_me:18709: result: $cf_gnat_projects" >&5
 echo "${ECHO_T}$cf_gnat_projects" >&6
 
 if test $cf_gnat_projects = yes
 then
-       echo "$as_me:18713: checking if GNAT supports libraries" >&5
+       echo "$as_me:18714: checking if GNAT supports libraries" >&5
 echo $ECHO_N "checking if GNAT supports libraries... $ECHO_C" >&6
-       echo "$as_me:18715: result: $cf_gnat_libraries" >&5
+       echo "$as_me:18716: result: $cf_gnat_libraries" >&5
 echo "${ECHO_T}$cf_gnat_libraries" >&6
 fi
 
@@ -18732,7 +18733,7 @@ else
        USE_GNAT_LIBRARIES="#"
 fi
 
-echo "$as_me:18735: checking for ada-compiler" >&5
+echo "$as_me:18736: checking for ada-compiler" >&5
 echo $ECHO_N "checking for ada-compiler... $ECHO_C" >&6
 
 # Check whether --with-ada-compiler or --without-ada-compiler was given.
@@ -18743,12 +18744,12 @@ else
   cf_ada_compiler=gnatmake
 fi;
 
-echo "$as_me:18746: result: $cf_ada_compiler" >&5
+echo "$as_me:18747: result: $cf_ada_compiler" >&5
 echo "${ECHO_T}$cf_ada_compiler" >&6
 
                        cf_ada_package=terminal_interface
 
-echo "$as_me:18751: checking for ada-include" >&5
+echo "$as_me:18752: checking for ada-include" >&5
 echo $ECHO_N "checking for ada-include... $ECHO_C" >&6
 
 # Check whether --with-ada-include or --without-ada-include was given.
@@ -18784,7 +18785,7 @@ case ".$withval" in #(vi
   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
   ;;
 *)
-  { { echo "$as_me:18787: error: expected a pathname, not \"$withval\"" >&5
+  { { echo "$as_me:18788: error: expected a pathname, not \"$withval\"" >&5
 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    { (exit 1); exit 1; }; }
   ;;
@@ -18793,10 +18794,10 @@ esac
 fi
 ADA_INCLUDE="$withval"
 
-echo "$as_me:18796: result: $ADA_INCLUDE" >&5
+echo "$as_me:18797: result: $ADA_INCLUDE" >&5
 echo "${ECHO_T}$ADA_INCLUDE" >&6
 
-echo "$as_me:18799: checking for ada-objects" >&5
+echo "$as_me:18800: checking for ada-objects" >&5
 echo $ECHO_N "checking for ada-objects... $ECHO_C" >&6
 
 # Check whether --with-ada-objects or --without-ada-objects was given.
@@ -18832,7 +18833,7 @@ case ".$withval" in #(vi
   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
   ;;
 *)
-  { { echo "$as_me:18835: error: expected a pathname, not \"$withval\"" >&5
+  { { echo "$as_me:18836: error: expected a pathname, not \"$withval\"" >&5
 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    { (exit 1); exit 1; }; }
   ;;
@@ -18841,10 +18842,10 @@ esac
 fi
 ADA_OBJECTS="$withval"
 
-echo "$as_me:18844: result: $ADA_OBJECTS" >&5
+echo "$as_me:18845: result: $ADA_OBJECTS" >&5
 echo "${ECHO_T}$ADA_OBJECTS" >&6
 
-echo "$as_me:18847: checking if an Ada95 shared-library should be built" >&5
+echo "$as_me:18848: checking if an Ada95 shared-library should be built" >&5
 echo $ECHO_N "checking if an Ada95 shared-library should be built... $ECHO_C" >&6
 
 # Check whether --with-ada-sharedlib or --without-ada-sharedlib was given.
@@ -18854,7 +18855,7 @@ if test "${with_ada_sharedlib+set}" = set; then
 else
   with_ada_sharedlib=no
 fi;
-echo "$as_me:18857: result: $with_ada_sharedlib" >&5
+echo "$as_me:18858: result: $with_ada_sharedlib" >&5
 echo "${ECHO_T}$with_ada_sharedlib" >&6
 
 ADA_SHAREDLIB='lib$(LIB_NAME).so.1'
@@ -18885,7 +18886,7 @@ fi
 ### chooses to split module lists into libraries.
 ###
 ### (see CF_LIB_RULES).
-echo "$as_me:18888: checking for library subsets" >&5
+echo "$as_me:18889: checking for library subsets" >&5
 echo $ECHO_N "checking for library subsets... $ECHO_C" >&6
 LIB_SUBSETS=
 
@@ -18926,7 +18927,7 @@ fi
 test "$with_widec"     = yes && LIB_SUBSETS="${LIB_SUBSETS}+widechar"
 test "$with_ext_funcs" = yes && LIB_SUBSETS="${LIB_SUBSETS}+ext_funcs"
 
-echo "$as_me:18929: result: $LIB_SUBSETS" >&5
+echo "$as_me:18930: result: $LIB_SUBSETS" >&5
 echo "${ECHO_T}$LIB_SUBSETS" >&6
 
 ### Construct the list of include-directories to be generated
@@ -18964,7 +18965,7 @@ elif test "$includedir" != "/usr/include"; then
 fi
 
 ### Build up pieces for makefile rules
-echo "$as_me:18967: checking default library suffix" >&5
+echo "$as_me:18968: checking default library suffix" >&5
 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in
@@ -18975,10 +18976,10 @@ echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
        shared)  DFT_ARG_SUFFIX=''   ;;
        esac
        test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
-echo "$as_me:18978: result: $DFT_ARG_SUFFIX" >&5
+echo "$as_me:18979: result: $DFT_ARG_SUFFIX" >&5
 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
 
-echo "$as_me:18981: checking default library-dependency suffix" >&5
+echo "$as_me:18982: checking default library-dependency suffix" >&5
 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in #(vi
@@ -19031,10 +19032,10 @@ echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
        esac
        test -n "$LIB_SUFFIX" && DFT_LIB_SUFFIX="${LIB_SUFFIX}${DFT_LIB_SUFFIX}"
        test -n "$LIB_SUFFIX" && DFT_DEP_SUFFIX="${LIB_SUFFIX}${DFT_DEP_SUFFIX}"
-echo "$as_me:19034: result: $DFT_DEP_SUFFIX" >&5
+echo "$as_me:19035: result: $DFT_DEP_SUFFIX" >&5
 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
 
-echo "$as_me:19037: checking default object directory" >&5
+echo "$as_me:19038: checking default object directory" >&5
 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
 
        case $DFT_LWR_MODEL in
@@ -19050,12 +19051,12 @@ echo $ECHO_N "checking default object directory... $ECHO_C" >&6
                        DFT_OBJ_SUBDIR='obj_s' ;;
                esac
        esac
-echo "$as_me:19053: result: $DFT_OBJ_SUBDIR" >&5
+echo "$as_me:19054: result: $DFT_OBJ_SUBDIR" >&5
 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
 
 # libtool thinks it can make c++ shared libraries (perhaps only g++)
 if test "$cf_with_cxx" = yes ; then
-echo "$as_me:19058: checking c++ library-dependency suffix" >&5
+echo "$as_me:19059: checking c++ library-dependency suffix" >&5
 echo $ECHO_N "checking c++ library-dependency suffix... $ECHO_C" >&6
 if test "$with_libtool" != "no"; then
        CXX_LIB_SUFFIX=$DFT_DEP_SUFFIX
@@ -19112,7 +19113,7 @@ else
        test -n "$LIB_SUFFIX" && CXX_LIB_SUFFIX="${LIB_SUFFIX}${CXX_LIB_SUFFIX}"
        test -n "$LIB_SUFFIX" && CXX_DEP_SUFFIX="${LIB_SUFFIX}${CXX_DEP_SUFFIX}"
 fi
-echo "$as_me:19115: result: $CXX_LIB_SUFFIX" >&5
+echo "$as_me:19116: result: $CXX_LIB_SUFFIX" >&5
 echo "${ECHO_T}$CXX_LIB_SUFFIX" >&6
 
 fi
 
 if test -n "$LDFLAGS_STATIC" && test -n "$LDFLAGS_SHARED"
 then
-       echo "$as_me:19274: checking if linker supports switching between static/dynamic" >&5
+       echo "$as_me:19275: checking if linker supports switching between static/dynamic" >&5
 echo $ECHO_N "checking if linker supports switching between static/dynamic... $ECHO_C" >&6
 
        rm -f libconftest.a
        cat >conftest.$ac_ext <<EOF
-#line 19279 "configure"
+#line 19280 "configure"
 #include <stdio.h>
 int cf_ldflags_static(FILE *fp) { return fflush(fp); }
 EOF
-       if { (eval echo "$as_me:19283: \"$ac_compile\"") >&5
+       if { (eval echo "$as_me:19284: \"$ac_compile\"") >&5
   (eval $ac_compile) 2>&5
   ac_status=$?
-  echo "$as_me:19286: \$? = $ac_status" >&5
+  echo "$as_me:19287: \$? = $ac_status" >&5
   (exit $ac_status); } ; then
                ( $AR $ARFLAGS libconftest.a conftest.o ) 2>&5 1>/dev/null
                ( eval $RANLIB libconftest.a ) 2>&5 >/dev/null
@@ -19294,10 +19295,10 @@ EOF
 
        LIBS="$LDFLAGS_STATIC -L`pwd` -lconftest $LDFLAGS_DYNAMIC $LIBS"
        cat >conftest.$ac_ext <<_ACEOF
-#line 19297 "configure"
+#line 19298 "configure"
 #include "confdefs.h"
 
-#line 19300 "configure"
+#line 19301 "configure"
 #include <stdio.h>
 int cf_ldflags_static(FILE *fp);
 
@@ -19312,16 +19313,16 @@ main ()
 }
 _ACEOF
 rm -f conftest.$ac_objext conftest$ac_exeext
-if { (eval echo "$as_me:19315: \"$ac_link\"") >&5
+if { (eval echo "$as_me:19316: \"$ac_link\"") >&5
   (eval $ac_link) 2>&5
   ac_status=$?
-  echo "$as_me:19318: \$? = $ac_status" >&5
+  echo "$as_me:19319: \$? = $ac_status" >&5
   (exit $ac_status); } &&
          { ac_try='test -s conftest$ac_exeext'
-  { (eval echo "$as_me:19321: \"$ac_try\"") >&5
+  { (eval echo "$as_me:19322: \"$ac_try\"") >&5
   (eval $ac_try) 2>&5
   ac_status=$?
-  echo "$as_me:19324: \$? = $ac_status" >&5
+  echo "$as_me:19325: \$? = $ac_status" >&5
   (exit $ac_status); }; }; then
 
        # some linkers simply ignore the -dynamic
@@ -19344,7 +19345,7 @@ rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
        rm -f libconftest.*
        LIBS="$cf_save_LIBS"
 
-       echo "$as_me:19347: result: $cf_ldflags_static" >&5
+       echo "$as_me:19348: result: $cf_ldflags_static" >&5
 echo "${ECHO_T}$cf_ldflags_static" >&6
 
        if test $cf_ldflags_static != yes
        ;;
 esac
 
-echo "$as_me:19363: checking where we will install curses.h" >&5
+echo "$as_me:19364: checking where we will install curses.h" >&5
 echo $ECHO_N "checking where we will install curses.h... $ECHO_C" >&6
 test "$with_overwrite" = no && \
 test "x$includedir" = 'x${prefix}/include' && \
        includedir='${prefix}/include/ncurses'${LIB_SUFFIX}
-echo "$as_me:19368: result: $includedir" >&5
+echo "$as_me:19369: result: $includedir" >&5
 echo "${ECHO_T}$includedir" >&6
 
 ### Resolve a conflict between normal and wide-curses by forcing applications
@@ -19373,7 +19374,7 @@ echo "${ECHO_T}$includedir" >&6
 if test "$with_overwrite" != no ; then
 if test "$NCURSES_LIBUTF8" = 1 ; then
        NCURSES_LIBUTF8='defined(HAVE_LIBUTF8_H)'
-       { echo "$as_me:19376: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5
+       { echo "$as_me:19377: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5
 echo "$as_me: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&2;}
 fi
 fi
@@ -19390,7 +19391,7 @@ EOF
 ### Construct the list of subdirectories for which we'll customize makefiles
 ### with the appropriate compile-rules.
 
-echo "$as_me:19393: checking for src modules" >&5
+echo "$as_me:19394: checking for src modules" >&5
 echo $ECHO_N "checking for src modules... $ECHO_C" >&6
 
 # dependencies and linker-arguments for test-programs
@@ -19453,7 +19454,7 @@ EOF
                fi
        fi
 done
-echo "$as_me:19456: result: $cf_cv_src_modules" >&5
+echo "$as_me:19457: result: $cf_cv_src_modules" >&5
 echo "${ECHO_T}$cf_cv_src_modules" >&6
 
 TEST_ARGS="-L${LIB_DIR} $TEST_ARGS"
@@ -19475,7 +19476,7 @@ test -z "$MAKE_TERMINFO" && SRC_SUBDIRS="$SRC_SUBDIRS misc"
 test "$cf_with_cxx_binding" != no && SRC_SUBDIRS="$SRC_SUBDIRS c++"
 
 ADA_SUBDIRS=
-if test "$cf_cv_prog_gnat_correct" = yes && test -f $srcdir/Ada95/Makefile.in; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = xyes && test -f $srcdir/Ada95/Makefile.in; then
        SRC_SUBDIRS="$SRC_SUBDIRS Ada95"
        ADA_SUBDIRS="gen src"
        if test "x$cf_with_tests" != "xno" ; then
@@ -19497,7 +19498,7 @@ if test -n "$ADA_SUBDIRS"; then
 
 fi
 
-if test "$cf_with_ada" != "no" && test "$cf_cv_prog_gnat_correct" != "no"; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then
    SUB_MAKEFILES="$SUB_MAKEFILES Ada95/gen/adacurses${DFT_ARG_SUFFIX}-config:Ada95/gen/adacurses-config.in"
    SUB_MAKEFILES="$SUB_MAKEFILES man/adacurses${DFT_ARG_SUFFIX}-config.1:man/MKada_config.in"
 fi
@@ -19659,7 +19660,7 @@ fi
 
 # Extract the first word of "tic", so it can be a program name with args.
 set dummy tic; ac_word=$2
-echo "$as_me:19662: checking for $ac_word" >&5
+echo "$as_me:19663: checking for $ac_word" >&5
 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
 if test "${ac_cv_path_TIC_PATH+set}" = set; then
   echo $ECHO_N "(cached) $ECHO_C" >&6
@@ -19676,7 +19677,7 @@ for ac_dir in $ac_dummy; do
   test -z "$ac_dir" && ac_dir=.
   if $as_executable_p "$ac_dir/$ac_word"; then
    ac_cv_path_TIC_PATH="$ac_dir/$ac_word"
-   echo "$as_me:19679: found $ac_dir/$ac_word" >&5
+   echo "$as_me:19680: found $ac_dir/$ac_word" >&5
    break
 fi
 done
 TIC_PATH=$ac_cv_path_TIC_PATH
 
 if test -n "$TIC_PATH"; then
-  echo "$as_me:19691: result: $TIC_PATH" >&5
+  echo "$as_me:19692: result: $TIC_PATH" >&5
 echo "${ECHO_T}$TIC_PATH" >&6
 else
-  echo "$as_me:19694: result: no" >&5
+  echo "$as_me:19695: result: no" >&5
 echo "${ECHO_T}no" >&6
 fi
 
@@ -19699,7 +19700,7 @@ if test -n "$FALLBACK_LIST"
 then
        if test "$TIC_PATH" = unknown
        then
-               { echo "$as_me:19702: WARNING: no tic program found for fallbacks" >&5
+               { echo "$as_me:19703: WARNING: no tic program found for fallbacks" >&5
 echo "$as_me: WARNING: no tic program found for fallbacks" >&2;}
        fi
 fi
@@ -19800,7 +19801,7 @@ DEFS=-DHAVE_CONFIG_H
 : ${CONFIG_STATUS=./config.status}
 ac_clean_files_save=$ac_clean_files
 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
-{ echo "$as_me:19803: creating $CONFIG_STATUS" >&5
+{ echo "$as_me:19804: creating $CONFIG_STATUS" >&5
 echo "$as_me: creating $CONFIG_STATUS" >&6;}
 cat >$CONFIG_STATUS <<_ACEOF
 #! $SHELL
@@ -19976,7 +19977,7 @@ cat >>$CONFIG_STATUS <<\EOF
     echo "$ac_cs_version"; exit 0 ;;
   --he | --h)
     # Conflict between --help and --header
-    { { echo "$as_me:19979: error: ambiguous option: $1
+    { { echo "$as_me:19980: error: ambiguous option: $1
 Try \`$0 --help' for more information." >&5
 echo "$as_me: error: ambiguous option: $1
 Try \`$0 --help' for more information." >&2;}
@@ -19995,7 +19996,7 @@ Try \`$0 --help' for more information." >&2;}
     ac_need_defaults=false;;
 
   # This is an error.
-  -*) { { echo "$as_me:19998: error: unrecognized option: $1
+  -*) { { echo "$as_me:19999: error: unrecognized option: $1
 Try \`$0 --help' for more information." >&5
 echo "$as_me: error: unrecognized option: $1
 Try \`$0 --help' for more information." >&2;}
@@ -20101,7 +20102,7 @@ do
   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
   "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
-  *) { { echo "$as_me:20104: error: invalid argument: $ac_config_target" >&5
+  *) { { echo "$as_me:20105: error: invalid argument: $ac_config_target" >&5
 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
    { (exit 1); exit 1; }; };;
   esac
@@ -20514,7 +20515,7 @@ done; }
   esac
 
   if test x"$ac_file" != x-; then
-    { echo "$as_me:20517: creating $ac_file" >&5
+    { echo "$as_me:20518: creating $ac_file" >&5
 echo "$as_me: creating $ac_file" >&6;}
     rm -f "$ac_file"
   fi
@@ -20532,7 +20533,7 @@ echo "$as_me: creating $ac_file" >&6;}
       -) echo $tmp/stdin ;;
       [\\/$]*)
          # Absolute (can't be DOS-style, as IFS=:)
-         test -f "$f" || { { echo "$as_me:20535: error: cannot find input file: $f" >&5
+         test -f "$f" || { { echo "$as_me:20536: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          echo $f;;
@@ -20545,7 +20546,7 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
            echo $srcdir/$f
          else
            # /dev/null tree
-           { { echo "$as_me:20548: error: cannot find input file: $f" >&5
+           { { echo "$as_me:20549: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          fi;;
@@ -20611,7 +20612,7 @@ for ac_file in : $CONFIG_HEADERS; do test "x$ac_file" = x: && continue
   * )   ac_file_in=$ac_file.in ;;
   esac
 
-  test x"$ac_file" != x- && { echo "$as_me:20614: creating $ac_file" >&5
+  test x"$ac_file" != x- && { echo "$as_me:20615: creating $ac_file" >&5
 echo "$as_me: creating $ac_file" >&6;}
 
   # First look for the input files in the build tree, otherwise in the
@@ -20622,7 +20623,7 @@ echo "$as_me: creating $ac_file" >&6;}
       -) echo $tmp/stdin ;;
       [\\/$]*)
          # Absolute (can't be DOS-style, as IFS=:)
-         test -f "$f" || { { echo "$as_me:20625: error: cannot find input file: $f" >&5
+         test -f "$f" || { { echo "$as_me:20626: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          echo $f;;
@@ -20635,7 +20636,7 @@ echo "$as_me: error: cannot find input file: $f" >&2;}
            echo $srcdir/$f
          else
            # /dev/null tree
-           { { echo "$as_me:20638: error: cannot find input file: $f" >&5
+           { { echo "$as_me:20639: error: cannot find input file: $f" >&5
 echo "$as_me: error: cannot find input file: $f" >&2;}
    { (exit 1); exit 1; }; }
          fi;;
@@ -20693,7 +20694,7 @@ cat >>$CONFIG_STATUS <<\EOF
   rm -f $tmp/in
   if test x"$ac_file" != x-; then
     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
-      { echo "$as_me:20696: $ac_file is unchanged" >&5
+      { echo "$as_me:20697: $ac_file is unchanged" >&5
 echo "$as_me: $ac_file is unchanged" >&6;}
     else
       ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
@@ -21336,7 +21337,7 @@ CF_EOF
        fi
 done
 
-if test "x$cf_with_ada" != xno ; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then
 if test -z "$USE_OLD_MAKERULES" ; then
        $AWK -f $srcdir/Ada95/mk-1st.awk <$srcdir/Ada95/src/modules >>Ada95/src/Makefile
 fi
index 412ae0f18c8519259801af7982af4d21a8633f9c..c5328db7b2ef8a1df4ccf98ae1dad50643289118 100644 (file)
@@ -28,14 +28,14 @@ dnl***************************************************************************
 dnl
 dnl Author: Thomas E. Dickey 1995-on
 dnl
-dnl $Id: configure.in,v 1.526 2011/09/24 14:40:59 nix Exp $
+dnl $Id: configure.in,v 1.527 2011/10/22 18:56:06 tom Exp $
 dnl Process this file with autoconf to produce a configure script.
 dnl
 dnl See http://invisible-island.net/autoconf/ for additional information.
 dnl
 dnl ---------------------------------------------------------------------------
 AC_PREREQ(2.13.20020210)
-AC_REVISION($Revision: 1.526 $)
+AC_REVISION($Revision: 1.527 $)
 AC_INIT(ncurses/base/lib_initscr.c)
 AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
 
@@ -1848,7 +1848,7 @@ AC_DEFINE(HAVE_SLK_COLOR)
 
 CF_SRC_MODULES($modules_to_build)
 
-if test "$cf_with_ada" != "no" && test "$cf_cv_prog_gnat_correct" != "no"; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then
    SUB_MAKEFILES="$SUB_MAKEFILES Ada95/gen/adacurses${DFT_ARG_SUFFIX}-config:Ada95/gen/adacurses-config.in"
    SUB_MAKEFILES="$SUB_MAKEFILES man/adacurses${DFT_ARG_SUFFIX}-config.1:man/MKada_config.in"
 fi
@@ -1929,7 +1929,7 @@ if test "x$cf_with_tests" != xno ; then
 fi
 CF_LIB_RULES($SRC_SUBDIRS)
 
-if test "x$cf_with_ada" != xno ; then
+if test "x$cf_with_ada" = "xyes" && test "x$cf_cv_prog_gnat_correct" = "xyes"; then
 if test -z "$USE_OLD_MAKERULES" ; then
        $AWK -f $srcdir/Ada95/mk-1st.awk <$srcdir/Ada95/src/modules >>Ada95/src/Makefile
 fi
diff --git a/dist.mk b/dist.mk
index 3b505c3bac50439be519d8bf1c2a860d9702f5fe..98edc09aea201aa3854b260de8d7ed45f8af71a6 100644 (file)
--- a/dist.mk
+++ b/dist.mk
@@ -25,7 +25,7 @@
 # use or other dealings in this Software without prior written               #
 # authorization.                                                             #
 ##############################################################################
-# $Id: dist.mk,v 1.839 2011/10/15 20:34:38 tom Exp $
+# $Id: dist.mk,v 1.840 2011/10/22 14:23:04 tom Exp $
 # Makefile for creating ncurses distributions.
 #
 # This only needs to be used directly as a makefile by developers, but
@@ -37,7 +37,7 @@ SHELL = /bin/sh
 # These define the major/minor/patch versions of ncurses.
 NCURSES_MAJOR = 5
 NCURSES_MINOR = 9
-NCURSES_PATCH = 20111015
+NCURSES_PATCH = 20111022
 
 # We don't append the patch to the version, since this only applies to releases
 VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
index da70906f552ff35312d73b1ff957820f998228b6..d893288b0e7a9b3a687286ceb560d16d0562f841 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
 /****************************************************************************
  *  Author: Thomas E. Dickey                    1996-on                     *
  ****************************************************************************/
-/* $Id: nc_alloc.h,v 1.18 2010/11/20 22:59:49 tom Exp $ */
+/* $Id: nc_alloc.h,v 1.19 2011/10/22 16:54:57 tom Exp $ */
 
 #ifndef NC_ALLOC_included
 #define NC_ALLOC_included 1
+/* *INDENT-OFF* */
 
 #ifdef __cplusplus
 extern "C" {
@@ -101,12 +102,14 @@ extern NCURSES_EXPORT(char *) _nc_strdup(const char *);
 /* entries.c */
 extern NCURSES_EXPORT(void) _nc_leaks_tinfo(void);
 
-#define typeMalloc(type,elts) (type *)malloc((elts)*sizeof(type))
-#define typeCalloc(type,elts) (type *)calloc((elts),sizeof(type))
-#define typeRealloc(type,elts,ptr) (type *)_nc_doalloc(ptr, (elts)*sizeof(type))
+#define typeMalloc(type,elts) (type *)malloc((size_t)(elts)*sizeof(type))
+#define typeCalloc(type,elts) (type *)calloc((size_t)(elts),sizeof(type))
+#define typeRealloc(type,elts,ptr) (type *)_nc_doalloc(ptr, (size_t)(elts)*sizeof(type))
 
 #ifdef __cplusplus
 }
 #endif
 
+/* *INDENT-ON* */
+
 #endif /* NC_ALLOC_included */
index 65e6bfc636202c190bdc1de2a11929fb4615efb0..72790e840545d7ad89fb9be83bfe90fba9c2115c 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1999-2006,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 1999-2009,2011 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            *
@@ -33,7 +33,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: keybound.c,v 1.10 2009/10/24 22:15:47 tom Exp $")
+MODULE_ID("$Id: keybound.c,v 1.11 2011/10/22 16:47:05 tom Exp $")
 
 /*
  * Returns the count'th string definition which is associated with the
@@ -46,7 +46,10 @@ NCURSES_SP_NAME(keybound) (NCURSES_SP_DCLx int code, int count)
 
     T((T_CALLED("keybound(%p, %d,%d)"), (void *) SP_PARM, code, count));
     if (SP_PARM != 0 && code >= 0) {
-       result = _nc_expand_try(SP_PARM->_keytry, (unsigned) code, &count, 0);
+       result = _nc_expand_try(SP_PARM->_keytry,
+                               (unsigned) code,
+                               &count,
+                               (size_t) 0);
     }
     returnPtr(result);
 }
index d700be491038d9c691d84ad9cc15cf859dac313e..6127fd2796de75ea49b44aa843002f85ad1e913c 100644 (file)
@@ -33,7 +33,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: keyok.c,v 1.11 2011/06/04 19:24:16 tom Exp $")
+MODULE_ID("$Id: keyok.c,v 1.12 2011/10/22 17:03:22 tom Exp $")
 
 /*
  * Enable (or disable) ncurses' interpretation of a keycode by adding (or
@@ -62,8 +62,8 @@ NCURSES_SP_NAME(keyok) (NCURSES_SP_DCLx int c, bool flag)
            unsigned ch = (unsigned) c;
 
            if (flag) {
-               while ((s = _nc_expand_try(SP_PARM->_key_ok, ch, &count, 0))
-                      != 0
+               while ((s = _nc_expand_try(SP_PARM->_key_ok,
+                                          ch, &count, (size_t) 0)) != 0
                       && _nc_remove_key(&(SP_PARM->_key_ok), ch)) {
                    code = _nc_add_to_try(&(SP_PARM->_keytry), s, ch);
                    free(s);
@@ -72,8 +72,8 @@ NCURSES_SP_NAME(keyok) (NCURSES_SP_DCLx int c, bool flag)
                        break;
                }
            } else {
-               while ((s = _nc_expand_try(SP_PARM->_keytry, ch, &count, 0))
-                      != 0
+               while ((s = _nc_expand_try(SP_PARM->_keytry,
+                                          ch, &count, (size_t) 0)) != 0
                       && _nc_remove_key(&(SP_PARM->_keytry), ch)) {
                    code = _nc_add_to_try(&(SP_PARM->_key_ok), s, ch);
                    free(s);
index 515ebaf0b8fc551a269af9ed7b7cda0ff85cb32e..dd6f800e6b6f9fff70c79e228f9fd6b998e4d39f 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -36,7 +36,7 @@
 #include <curses.priv.h>
 #include <ctype.h>
 
-MODULE_ID("$Id: lib_addch.c,v 1.124 2010/04/24 22:41:05 tom Exp $")
+MODULE_ID("$Id: lib_addch.c,v 1.125 2011/10/22 16:51:31 tom Exp $")
 
 static const NCURSES_CH_T blankchar = NewChar(BLANK_TEXT);
 
@@ -209,7 +209,8 @@ _nc_build_wch(WINDOW *win, ARG_CH_T ch)
     buffer[WINDOW_EXT(win, addch_used)] = '\0';
     if ((len = (int) mbrtowc(&result,
                             buffer,
-                            WINDOW_EXT(win, addch_used), &state)) > 0) {
+                            (size_t) WINDOW_EXT(win, addch_used),
+                            &state)) > 0) {
        attr_t attrs = AttrOf(CHDEREF(ch));
        if_EXT_COLORS(int pair = GetPair(CHDEREF(ch)));
        SetChar(CHDEREF(ch), result, attrs);
index f0d2006b71ab9ce2a79849fc029a92a10ad4ac46..5495c6003dc54cf54468828aa18143f81b714843 100644 (file)
@@ -45,7 +45,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_color.c,v 1.103 2011/07/23 22:00:34 tom Exp $")
+MODULE_ID("$Id: lib_color.c,v 1.104 2011/10/22 15:53:42 tom Exp $")
 
 #ifdef USE_TERM_DRIVER
 #define CanChange      InfoOf(SP_PARM).canchange
@@ -390,10 +390,10 @@ start_color(void)
 
 /* This function was originally written by Daniel Weaver <danw@znyx.com> */
 static void
-rgb2hls(short r, short g, short b, short *h, short *l, short *s)
+rgb2hls(int r, int g, int b, short *h, short *l, short *s)
 /* convert RGB to HLS system */
 {
-    short min, max, t;
+    int min, max, t;
 
     if ((min = g < r ? g : r) > b)
        min = b;
@@ -423,7 +423,7 @@ rgb2hls(short r, short g, short b, short *h, short *l, short *s)
     else
        t = (short) (360 + ((r - g) * 60) / (max - min));
 
-    *h = t % 360;
+    *h = (short) (t % 360);
 }
 
 /*
@@ -782,9 +782,9 @@ pair_content(short pair, short *f, short *b)
 
 NCURSES_EXPORT(void)
 NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_DCLx
-                              short old_pair,
-                              short pair,
-                              bool reverse,
+                              int old_pair,
+                              int pair,
+                              int reverse,
                               NCURSES_SP_OUTC outc)
 {
 #ifdef USE_TERM_DRIVER
@@ -864,7 +864,7 @@ NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_DCLx
 
 #if NCURSES_SP_FUNCS
 NCURSES_EXPORT(void)
-_nc_do_color(short old_pair, short pair, bool reverse, NCURSES_OUTC outc)
+_nc_do_color(int old_pair, int pair, int reverse, NCURSES_OUTC outc)
 {
     SetSafeOutcWrapper(outc);
     NCURSES_SP_NAME(_nc_do_color) (CURRENT_SCREEN,
index 5bcc974bc2577d27a03990e29273c4467823fa1f..693877879a60268712434cb5c8576851243ab0eb 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -39,7 +39,7 @@
 extern int malloc_errfd;       /* FIXME */
 #endif
 
-MODULE_ID("$Id: lib_freeall.c,v 1.59 2010/01/23 17:57:43 tom Exp $")
+MODULE_ID("$Id: lib_freeall.c,v 1.60 2011/10/22 16:34:50 tom Exp $")
 
 /*
  * Free all ncurses data.  This is used for testing only (there's no practical
@@ -100,7 +100,7 @@ NCURSES_SP_NAME(_nc_freeall) (NCURSES_SP_DCL0)
 
     (void) _nc_printf_string(0, empty_va);
 #ifdef TRACE
-    (void) _nc_trace_buf(-1, 0);
+    (void) _nc_trace_buf(-1, (size_t) 0);
 #endif
 #if USE_WIDEC_SUPPORT
     FreeIfNeeded(_nc_wacs);
index 130c502431b3d2d74044f114ff465df2cbbf8df5..7ee9e794a93c5989ad085e95512aec4fd277973c 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -42,7 +42,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_getch.c,v 1.121 2010/12/25 23:24:04 tom Exp $")
+MODULE_ID("$Id: lib_getch.c,v 1.122 2011/10/22 16:34:50 tom Exp $")
 
 #include <fifo_defs.h>
 
@@ -270,7 +270,7 @@ fifo_push(SCREEN *sp EVENTLIST_2nd(_nc_eventlist * evl))
 #  endif
            _nc_globals.read_thread = pthread_self();
 # endif
-       n = (int) read(sp->_ifd, &c2, 1);
+       n = (int) read(sp->_ifd, &c2, (size_t) 1);
 #if USE_PTHREADS_EINTR
        _nc_globals.read_thread = 0;
 #endif
index 21d8baa05c8be0968bb80b1730a8ba637cb2d7b8..0e446349ca173ae0a0a64ba5b55b2f343fd04564 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2009,2011 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            *
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_getstr.c,v 1.29 2009/10/24 21:59:02 tom Exp $")
+MODULE_ID("$Id: lib_getstr.c,v 1.30 2011/10/22 16:31:35 tom Exp $")
 
 /*
  * This wipes out the last character, no matter whether it was a tab, control
  * or other character, and handles reverse wraparound.
  */
 static char *
-WipeOut(WINDOW *win, int y, int x, char *first, char *last, bool echoed)
+WipeOut(WINDOW *win, int y, int x, char *first, char *last, int echoed)
 {
     if (last > first) {
        *--last = '\0';
index e6d1a739c94f47023e8966678f654fe2d7689214..aadf8b43112889987108aa1465fd0f2640f98cf3 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2009,2011 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            *
@@ -41,7 +41,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_instr.c,v 1.17 2009/10/24 22:55:45 tom Exp $")
+MODULE_ID("$Id: lib_instr.c,v 1.18 2011/10/22 16:31:35 tom Exp $")
 
 NCURSES_EXPORT(int)
 winnstr(WINDOW *win, char *str, int n)
@@ -78,7 +78,7 @@ winnstr(WINDOW *win, char *str, int n)
                    if (getcchar(cell, wch, &attrs, &pair, 0) == OK) {
 
                        init_mb(state);
-                       n3 = wcstombs(0, wch, 0);
+                       n3 = wcstombs(0, wch, (size_t) 0);
                        if (!isEILSEQ(n3) && (n3 != 0)) {
                            if (((int) n3 + i) > n) {
                                done = TRUE;
index 8b807cce948c24c19df7edb8dfeabb4093468611..783ed0c25307f1af90848ff42523bfd200d3e2d1 100644 (file)
@@ -84,7 +84,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_mouse.c,v 1.130 2011/09/24 00:42:25 tom Exp $")
+MODULE_ID("$Id: lib_mouse.c,v 1.133 2011/10/22 23:01:26 tom Exp $")
 
 #include <tic.h>
 
@@ -148,6 +148,9 @@ make an error
 #define INVALID_EVENT  -1
 #define NORMAL_EVENT   0
 
+#define ValidEvent(ep) ((ep)->id != INVALID_EVENT)
+#define Invalidate(ep) (ep)->id = INVALID_EVENT
+
 #if USE_GPM_SUPPORT
 
 #ifndef LIBGPM_SONAME
@@ -673,7 +676,7 @@ _nc_mouse_init(SCREEN *sp)
 
            sp->_mouse_eventp = FirstEV(sp);
            for (i = 0; i < EV_MAX; i++)
-               sp->_mouse_events[i].id = INVALID_EVENT;
+               Invalidate(sp->_mouse_events + i);
 
            initialize_mousetype(sp);
 
@@ -1002,7 +1005,7 @@ _nc_mouse_inline(SCREEN *sp)
 }
 
 static void
-mouse_activate(SCREEN *sp, bool on)
+mouse_activate(SCREEN *sp, int on)
 {
     if (!on && !sp->_mouse_initialized)
        return;
@@ -1133,7 +1136,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
      */
     ep = eventp;
     for (n = runcount; n < EV_MAX; n++) {
-       ep->id = INVALID_EVENT;
+       Invalidate(ep);
        ep = NEXT(ep);
     }
 
@@ -1159,7 +1162,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
 #define MASK_CHANGED(x) (!(ep->bstate & MASK_PRESS(x)) \
                      == !(next->bstate & MASK_RELEASE(x)))
 
-           if (ep->id != INVALID_EVENT && next->id != INVALID_EVENT
+           if (ValidEvent(ep) && ValidEvent(next)
                && ep->x == next->x && ep->y == next->y
                && (ep->bstate & BUTTON_PRESSED)
                && (!(next->bstate & BUTTON_PRESSED))) {
@@ -1182,14 +1185,15 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
                            merge = TRUE;
                        }
                    }
-                   if (merge)
-                       ep->id = INVALID_EVENT;
+                   if (merge) {
+                       Invalidate(ep);
+                   }
                }
            }
        }
 
        /* Compact valid events */
-       if (ep->id == INVALID_EVENT) {
+       if (!ValidEvent(ep)) {
            if ((first_valid != NULL) && (first_invalid == NULL)) {
                first_invalid = ep;
            }
@@ -1198,7 +1202,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
                first_valid = ep;
            } else if (first_invalid != NULL) {
                *first_invalid = *ep;
-               ep->id = INVALID_EVENT;
+               Invalidate(ep);
                first_invalid = NEXT(first_invalid);
            }
        }
@@ -1247,6 +1251,8 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
        if (next == eventp) {
            /* Will end the loop, but check event type and compact before */
            endLoop = TRUE;
+       } else if (!ValidEvent(next)) {
+           continue;
        } else {
            /* merge click events forward */
            if ((ep->bstate & BUTTON_CLICKED)
@@ -1261,8 +1267,9 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
                        merge = TRUE;
                    }
                }
-               if (merge)
-                   ep->id = INVALID_EVENT;
+               if (merge) {
+                   Invalidate(ep);
+               }
            }
 
            /* merge double-click events forward */
@@ -1278,18 +1285,19 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
                        merge = TRUE;
                    }
                }
-               if (merge)
-                   ep->id = INVALID_EVENT;
+               if (merge) {
+                   Invalidate(ep);
+               }
            }
        }
 
        /* Discard event if it does not match event mask */
-       if (!(ep->bstate & sp->_mouse_mask)) {
-           ep->id = INVALID_EVENT;
+       if (!(ep->bstate & sp->_mouse_mask2)) {
+           Invalidate(ep);
        }
 
        /* Compact valid events */
-       if (ep->id == INVALID_EVENT) {
+       if (!ValidEvent(ep)) {
            if (ep == first_valid) {
                first_valid = next;
            } else if (first_invalid == NULL) {
@@ -1297,7 +1305,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
            }
        } else if (first_invalid != NULL) {
            *first_invalid = *ep;
-           ep->id = INVALID_EVENT;
+           Invalidate(ep);
            first_invalid = NEXT(first_invalid);
        }
 
@@ -1319,7 +1327,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
            _nc_unlock_global(tracef);
        }
        for (ep = first_valid; ep != first_invalid; ep = NEXT(ep)) {
-           if (ep->id != INVALID_EVENT)
+           if (ValidEvent(ep))
                TR(MY_TRACE,
                   ("_nc_mouse_parse: returning composite mouse event %s at slot %ld",
                    _nc_tracemouse(sp, ep),
@@ -1329,7 +1337,7 @@ _nc_mouse_parse(SCREEN *sp, int runcount)
 #endif /* TRACE */
 
     /* after all this, do we have a valid event? */
-    return (PREV(first_invalid)->id != INVALID_EVENT);
+    return ValidEvent(PREV(first_invalid));
 }
 
 static void
@@ -1426,11 +1434,11 @@ NCURSES_SP_NAME(getmouse) (NCURSES_SP_DCLx MEVENT * aevent)
         * _nc_mouse_parse was not called, e.g., when _nc_mouse_inline returns
         * false).
         */
-       while ((prev->id != INVALID_EVENT) && (!(prev->bstate & SP_PARM->_mouse_mask))) {
-           prev->id = INVALID_EVENT;
+       while (ValidEvent(prev) && (!(prev->bstate & SP_PARM->_mouse_mask2))) {
+           Invalidate(prev);
            prev = PREV(prev);
        }
-       if (prev->id != INVALID_EVENT) {
+       if (ValidEvent(prev)) {
            /* copy the event we find there */
            *aevent = *prev;
 
@@ -1438,13 +1446,13 @@ NCURSES_SP_NAME(getmouse) (NCURSES_SP_DCLx MEVENT * aevent)
                              _nc_tracemouse(SP_PARM, prev),
                              (long) IndexEV(SP_PARM, prev)));
 
-           prev->id = INVALID_EVENT;   /* so the queue slot becomes free */
+           Invalidate(prev);   /* so the queue slot becomes free */
            SP_PARM->_mouse_eventp = prev;
            result = OK;
        } else {
            /* Reset the provided event */
            aevent->bstate = 0;
-           aevent->id = INVALID_EVENT;
+           Invalidate(aevent);
            aevent->x = 0;
            aevent->y = 0;
            aevent->z = 0;
@@ -1498,6 +1506,7 @@ NCURSES_SP_NAME(mousemask) (NCURSES_SP_DCLx mmask_t newmask, mmask_t * oldmask)
 /* set the mouse event mask */
 {
     mmask_t result = 0;
+    int b;
 
     T((T_CALLED("mousemask(%p,%#lx,%p)"),
        (void *) SP_PARM,
@@ -1525,6 +1534,22 @@ NCURSES_SP_NAME(mousemask) (NCURSES_SP_DCLx mmask_t newmask, mmask_t * oldmask)
                mouse_activate(SP_PARM, (bool) (result != 0));
 
                SP_PARM->_mouse_mask = result;
+               SP_PARM->_mouse_mask2 = result;
+
+               /*
+                * Make a mask corresponding to the states we will need to
+                * retain (temporarily) while building up the state that the
+                * user asked for.
+                */
+               for (b = 1; b <= MAX_BUTTONS; ++b) {
+                   if (SP_PARM->_mouse_mask2 & MASK_TRIPLE_CLICK(b))
+                       SP_PARM->_mouse_mask2 |= MASK_DOUBLE_CLICK(b);
+                   if (SP_PARM->_mouse_mask2 & MASK_DOUBLE_CLICK(b))
+                       SP_PARM->_mouse_mask2 |= MASK_CLICK(b);
+                   if (SP_PARM->_mouse_mask2 & MASK_CLICK(b))
+                       SP_PARM->_mouse_mask2 |= (MASK_PRESS(b) |
+                                                 MASK_RELEASE(b));
+               }
            }
        }
     }
index a8621e63e17273d1cd8c71d5742a436f36e11cb8..637aa46ece01ab0921bb18216e9428f9999a1eb9 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2001,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2009,2011 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            *
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_scanw.c,v 1.12 2009/10/24 22:35:14 tom Exp $")
+MODULE_ID("$Id: lib_scanw.c,v 1.13 2011/10/22 16:31:35 tom Exp $")
 
 NCURSES_EXPORT(int)
 vwscanw(WINDOW *win, NCURSES_CONST char *fmt, va_list argp)
 {
     char buf[BUFSIZ];
 
-    if (wgetnstr(win, buf, sizeof(buf) - 1) == ERR)
+    if (wgetnstr(win, buf, (int) sizeof(buf) - 1) == ERR)
        return (ERR);
 
     return (vsscanf(buf, fmt, argp));
index 7404caacf490580a7ce9a22fc8e362f86e62c896..695ed30e7e1000b98011a70b6c0624921ab6ca58 100644 (file)
@@ -39,7 +39,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_screen.c,v 1.40 2011/05/28 23:03:44 tom Exp $")
+MODULE_ID("$Id: lib_screen.c,v 1.41 2011/10/22 15:03:11 tom Exp $")
 
 #define MAX_SIZE 0x3fff                /* 16k is big enough for a window or pad */
 
@@ -55,7 +55,7 @@ NCURSES_SP_NAME(getwin) (NCURSES_SP_DCLx FILE *filep)
        returnWin(0);
     }
     clearerr(filep);
-    if (fread(&tmp, 1, sizeof(WINDOW), filep) < sizeof(WINDOW)
+    if (fread(&tmp, (size_t) 1, sizeof(WINDOW), filep) < sizeof(WINDOW)
        || ferror(filep)
        || tmp._maxy == 0
        || tmp._maxy > MAX_SIZE
@@ -113,7 +113,7 @@ NCURSES_SP_NAME(getwin) (NCURSES_SP_DCLx FILE *filep)
 
        for (n = 0; n <= nwin->_maxy; n++) {
            clearerr(filep);
-           if (fread(nwin->_line[n].text, 1, linesize, filep) < linesize
+           if (fread(nwin->_line[n].text, (size_t) 1, linesize, filep) < linesize
                || ferror(filep)) {
                delwin(nwin);
                returnWin(0);
@@ -144,7 +144,7 @@ putwin(WINDOW *win, FILE *filep)
        size_t len = (size_t) (win->_maxx + 1);
 
        clearerr(filep);
-       if (fwrite(win, sizeof(WINDOW), 1, filep) != 1
+       if (fwrite(win, sizeof(WINDOW), (size_t) 1, filep) != 1
            || ferror(filep))
              returnCode(code);
 
index fe4e80804daef3de444430a3418cb7c587708ec3..8684e2519294f12d5c5e90bb10c38d102927ab1f 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_scroll.c,v 1.28 2010/12/19 01:48:09 tom Exp $")
+MODULE_ID("$Id: lib_scroll.c,v 1.29 2011/10/22 16:34:50 tom Exp $")
 
 NCURSES_EXPORT(void)
 _nc_scroll_window(WINDOW *win,
                  int const n,
-                 NCURSES_SIZE_T const top,
-                 NCURSES_SIZE_T const bottom,
+                 int const top,
+                 int const bottom,
                  NCURSES_CH_T blank)
 {
     int limit;
index c67cf8c1a9e374b7250235e9a8482a45ba9af8b0..b60242ded6d66b71597e0480453badcd65c803aa 100644 (file)
@@ -47,7 +47,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_set_term.c,v 1.139 2011/06/14 22:50:58 tom Exp $")
+MODULE_ID("$Id: lib_set_term.c,v 1.140 2011/10/22 16:10:43 tom Exp $")
 
 #ifdef USE_TERM_DRIVER
 #define MaxColors      InfoOf(sp).maxcolors
@@ -284,7 +284,7 @@ NCURSES_SP_NAME(_nc_setupscreen) (
                                     int slines,
                                     int scolumns,
                                     FILE *output,
-                                    bool filtered,
+                                    int filtered,
                                     int slk_format)
 {
     char *env;
@@ -695,7 +695,7 @@ NCURSES_EXPORT(int)
 _nc_setupscreen(int slines GCC_UNUSED,
                int scolumns GCC_UNUSED,
                FILE *output,
-               bool filtered,
+               int filtered,
                int slk_format)
 {
     SCREEN *sp = 0;
index 91483f103b23c687410b068cdc2d8a46ea1b3a3a..ca66266855eaec884ecb1e094750405a81a53626 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -44,7 +44,7 @@
 #endif
 #endif
 
-MODULE_ID("$Id: lib_slkset.c,v 1.21 2010/12/25 23:43:58 tom Exp $")
+MODULE_ID("$Id: lib_slkset.c,v 1.22 2011/10/22 16:58:26 tom Exp $")
 
 NCURSES_EXPORT(int)
 NCURSES_SP_NAME(slk_set) (NCURSES_SP_DCLx int i, const char *astr, int format)
@@ -111,8 +111,8 @@ NCURSES_SP_NAME(slk_set) (NCURSES_SP_DCLx int i, const char *astr, int format)
     slk->ent[i].ent_text[numchrs] = '\0';
 
     if ((slk->ent[i].form_text = (char *) _nc_doalloc(slk->ent[i].form_text,
-                                                     (unsigned) (limit +
-                                                                 numchrs + 1))
+                                                     (size_t) (limit +
+                                                               numchrs + 1))
        ) == 0)
        returnCode(ERR);
 
@@ -131,16 +131,16 @@ NCURSES_SP_NAME(slk_set) (NCURSES_SP_DCLx int i, const char *astr, int format)
     if (offset <= 0)
        offset = 0;
     else
-       memset(slk->ent[i].form_text, ' ', (unsigned) offset);
+       memset(slk->ent[i].form_text, ' ', (size_t) offset);
 
     memcpy(slk->ent[i].form_text + offset,
           slk->ent[i].ent_text,
-          (unsigned) numchrs);
+          (size_t) numchrs);
 
     if (offset < limit) {
        memset(slk->ent[i].form_text + offset + numchrs,
               ' ',
-              (unsigned) (limit - (offset + numcols)));
+              (size_t) (limit - (offset + numcols)));
     }
 
     slk->ent[i].form_text[numchrs - numcols + limit] = 0;
index 0d41aaacf653ae0a425564ff914631f3c9fb8c56..b6ffea4d23aadff7765f9f0692cac3e49c0f3460 100644 (file)
@@ -34,7 +34,7 @@
  ****************************************************************************/
 
 /*
- * $Id: curses.priv.h,v 1.485 2011/10/08 21:00:56 tom Exp $
+ * $Id: curses.priv.h,v 1.488 2011/10/22 22:41:12 tom Exp $
  *
  *     curses.priv.h
  *
@@ -1085,7 +1085,8 @@ struct screen {
        void            (*_mouse_wrap)  (SCREEN *);
        int             _mouse_fd;      /* file-descriptor, if any */
        bool            _mouse_active;  /* true if initialized */
-       mmask_t         _mouse_mask;
+       mmask_t         _mouse_mask;    /* set via mousemask() */
+       mmask_t         _mouse_mask2;   /* OR's in press/release bits */
        mmask_t         _mouse_bstate;
        NCURSES_CONST char *_mouse_xtermcap; /* string to enable/disable mouse */
        MEVENT          _mouse_events[EV_MAX];  /* hold the last mouse event seen */
@@ -1370,7 +1371,7 @@ extern NCURSES_EXPORT_VAR(SIG_ATOMIC_T) _nc_have_sigwinch;
                                        putc(PUTC_ch,b);                            \
                                    break;                                          \
                                }                                                   \
-                               IGNORE_RC(fwrite(PUTC_buf, (unsigned) PUTC_n, 1, b)); \
+                               IGNORE_RC(fwrite(PUTC_buf, (size_t) PUTC_n, (size_t) 1, b)); \
                            }                                                       \
                            COUNT_OUTCHARS(PUTC_i);                                 \
                        } } } while (0)
@@ -1559,7 +1560,7 @@ extern NCURSES_EXPORT(void)       _nc_locked_tracef (const char *, ...) GCC_PRINTFLIKE
 #define returnVoidPtr(code)    TRACE_RETURN(code,void_ptr)
 #define returnWin(code)                TRACE_RETURN(code,win)
 
-extern NCURSES_EXPORT(NCURSES_BOOL)     _nc_retrace_bool (NCURSES_BOOL);
+extern NCURSES_EXPORT(NCURSES_BOOL)     _nc_retrace_bool (int);
 extern NCURSES_EXPORT(NCURSES_CONST void *) _nc_retrace_cvoid_ptr (NCURSES_CONST void *);
 extern NCURSES_EXPORT(SCREEN *)         _nc_retrace_sp (SCREEN *);
 extern NCURSES_EXPORT(WINDOW *)         _nc_retrace_win (WINDOW *);
@@ -1570,7 +1571,7 @@ extern NCURSES_EXPORT(char *)           _nc_varargs (const char *, va_list);
 extern NCURSES_EXPORT(chtype)           _nc_retrace_chtype (chtype);
 extern NCURSES_EXPORT(const char *)     _nc_altcharset_name(attr_t, chtype);
 extern NCURSES_EXPORT(const char *)     _nc_retrace_cptr (const char *);
-extern NCURSES_EXPORT(char)             _nc_retrace_char (char);
+extern NCURSES_EXPORT(char)             _nc_retrace_char (int);
 extern NCURSES_EXPORT(int)              _nc_retrace_int (int);
 extern NCURSES_EXPORT(int)              _nc_retrace_int_attr_t (attr_t);
 extern NCURSES_EXPORT(mmask_t)          _nc_retrace_mmask_t (SCREEN *, mmask_t);
@@ -1847,8 +1848,8 @@ extern NCURSES_EXPORT(bool) _nc_has_mouse (SCREEN *);
 extern NCURSES_EXPORT(char *) _nc_get_locale(void);
 extern NCURSES_EXPORT(int)    _nc_unicode_locale(void);
 extern NCURSES_EXPORT(int)    _nc_locale_breaks_acs(TERMINAL *);
-extern NCURSES_EXPORT(int)    _nc_setupterm(NCURSES_CONST char *, int, int *, bool);
-extern NCURSES_EXPORT(void)   _nc_tinfo_cmdch(TERMINAL *, char);
+extern NCURSES_EXPORT(int)    _nc_setupterm(NCURSES_CONST char *, int, int *, int);
+extern NCURSES_EXPORT(void)   _nc_tinfo_cmdch(TERMINAL *, int);
 
 /* lib_set_term.c */
 extern NCURSES_EXPORT(int)    _nc_ripoffline(int, int(*)(WINDOW*, int));
@@ -1925,16 +1926,16 @@ extern NCURSES_EXPORT(int) _nc_access (const char *, int);
 extern NCURSES_EXPORT(int) _nc_baudrate (int);
 extern NCURSES_EXPORT(int) _nc_freewin (WINDOW *);
 extern NCURSES_EXPORT(int) _nc_getenv_num (const char *);
-extern NCURSES_EXPORT(int) _nc_keypad (SCREEN *, bool);
+extern NCURSES_EXPORT(int) _nc_keypad (SCREEN *, int);
 extern NCURSES_EXPORT(int) _nc_ospeed (int);
 extern NCURSES_EXPORT(int) _nc_outch (int);
 extern NCURSES_EXPORT(int) _nc_putp(const char *, const char *);
 extern NCURSES_EXPORT(int) _nc_putp_flush(const char *, const char *);
 extern NCURSES_EXPORT(int) _nc_read_termcap_entry (const char *const, TERMTYPE *const);
-extern NCURSES_EXPORT(int) _nc_setupscreen (int, int, FILE *, bool, int);
+extern NCURSES_EXPORT(int) _nc_setupscreen (int, int, FILE *, int, int);
 extern NCURSES_EXPORT(int) _nc_setup_tinfo(const char *, TERMTYPE *);
 extern NCURSES_EXPORT(int) _nc_timed_wait (SCREEN *, int, int, int * EVENTLIST_2nd(_nc_eventlist *));
-extern NCURSES_EXPORT(void) _nc_do_color (short, short, bool, NCURSES_OUTC);
+extern NCURSES_EXPORT(void) _nc_do_color (int, int, int, NCURSES_OUTC);
 extern NCURSES_EXPORT(void) _nc_flush (void);
 extern NCURSES_EXPORT(void) _nc_free_and_exit (int) GCC_NORETURN;
 extern NCURSES_EXPORT(void) _nc_free_entry (ENTRY *, TERMTYPE *);
@@ -1945,8 +1946,8 @@ extern NCURSES_EXPORT(void) _nc_keep_tic_dir (const char *);
 extern NCURSES_EXPORT(void) _nc_make_oldhash (int i);
 extern NCURSES_EXPORT(void) _nc_scroll_oldhash (int n, int top, int bot);
 extern NCURSES_EXPORT(void) _nc_scroll_optimize (void);
-extern NCURSES_EXPORT(void) _nc_set_buffer (FILE *, bool);
-extern NCURSES_EXPORT(void) _nc_signal_handler (bool);
+extern NCURSES_EXPORT(void) _nc_set_buffer (FILE *, int);
+extern NCURSES_EXPORT(void) _nc_signal_handler (int);
 extern NCURSES_EXPORT(void) _nc_synchook (WINDOW *);
 extern NCURSES_EXPORT(void) _nc_trace_tries (TRIES *);
 
@@ -1965,7 +1966,7 @@ extern NCURSES_EXPORT(void) _nc_tgetent_leaks(void);
 #if !(defined(USE_TERMLIB) || defined(USE_BUILD_CC))
 extern NCURSES_EXPORT(NCURSES_CH_T) _nc_render (WINDOW *, NCURSES_CH_T);
 extern NCURSES_EXPORT(int) _nc_waddch_nosync (WINDOW *, const NCURSES_CH_T);
-extern NCURSES_EXPORT(void) _nc_scroll_window (WINDOW *, int const, NCURSES_SIZE_T const, NCURSES_SIZE_T const, NCURSES_CH_T);
+extern NCURSES_EXPORT(void) _nc_scroll_window (WINDOW *, int const, int const, int const, NCURSES_CH_T);
 #endif
 
 #if USE_WIDEC_SUPPORT
@@ -1998,7 +1999,7 @@ extern NCURSES_EXPORT(int) _nc_eventlist_timeout(_nc_eventlist *);
  */
 #if USE_WIDEC_SUPPORT
 #if HAVE_MBTOWC && HAVE_MBLEN
-#define reset_mbytes(state) IGNORE_RC(mblen(NULL, 0)), IGNORE_RC(mbtowc(NULL, NULL, 0))
+#define reset_mbytes(state) IGNORE_RC(mblen(NULL, (size_t) 0)), IGNORE_RC(mbtowc(NULL, NULL, (size_t) 0))
 #define count_mbytes(buffer,length,state) mblen(buffer,length)
 #define check_mbytes(wch,buffer,length,state) \
        (int) mbtowc(&wch, buffer, length)
@@ -2135,39 +2136,39 @@ typedef struct _termInfo
 
 typedef struct term_driver {
     bool   isTerminfo;
-    bool   (*CanHandle)(struct DriverTCB*,const char*,int*);
+    bool   (*CanHandle)(struct DriverTCB*, const char*, int*);
     void   (*init)(struct DriverTCB*);
     void   (*release)(struct DriverTCB*);
     int    (*size)(struct DriverTCB*, int* Line, int *Cols);
-    int    (*sgmode)(struct DriverTCB*, bool setFlag, TTY*);
+    int    (*sgmode)(struct DriverTCB*, int setFlag, TTY*);
     chtype (*conattr)(struct DriverTCB*);
     int    (*hwcur)(struct DriverTCB*, int yold, int xold, int y, int x);
-    int    (*mode)(struct DriverTCB*, bool progFlag, bool defFlag);
+    int    (*mode)(struct DriverTCB*, int progFlag, int defFlag);
     bool   (*rescol)(struct DriverTCB*);
     bool   (*rescolors)(struct DriverTCB*);
-    void   (*color)(struct DriverTCB*,bool fore, int color, int(*)(SCREEN*,int));
-    int    (*doBeepOrFlash)(struct DriverTCB*, bool);
-    void   (*initpair)(struct DriverTCB*,short,short,short);
-    void   (*initcolor)(struct DriverTCB*,short,short,short,short);
-    void   (*docolor)(struct DriverTCB*,short,short,bool,int(*)(SCREEN*,int));
+    void   (*color)(struct DriverTCB*, int fore, int color, int(*)(SCREEN*, int));
+    int    (*doBeepOrFlash)(struct DriverTCB*, int);
+    void   (*initpair)(struct DriverTCB*, int, int, int);
+    void   (*initcolor)(struct DriverTCB*, int, int, int, int);
+    void   (*docolor)(struct DriverTCB*, int, int, int, int(*)(SCREEN*, int));
     void   (*initmouse)(struct DriverTCB*);
-    int    (*testmouse)(struct DriverTCB*,int);
+    int    (*testmouse)(struct DriverTCB*, int);
     void   (*setfilter)(struct DriverTCB*);
-    void   (*hwlabel)(struct DriverTCB*,int,char*);
-    void   (*hwlabelOnOff)(struct DriverTCB*,bool);
+    void   (*hwlabel)(struct DriverTCB*, int, char*);
+    void   (*hwlabelOnOff)(struct DriverTCB*, int);
     int    (*update)(struct DriverTCB*);
-    int    (*defaultcolors)(struct DriverTCB*,int,int);
-    int    (*print)(struct DriverTCB*,char*,int);
-    int    (*getsize)(struct DriverTCB*,int*,int*);
-    int    (*setsize)(struct DriverTCB*,int,int);
-    void   (*initacs)(struct DriverTCB*,chtype*,chtype*);
+    int    (*defaultcolors)(struct DriverTCB*, int, int);
+    int    (*print)(struct DriverTCB*, char*, int);
+    int    (*getsize)(struct DriverTCB*, int*, int*);
+    int    (*setsize)(struct DriverTCB*, int, int);
+    void   (*initacs)(struct DriverTCB*, chtype*, chtype*);
     void   (*scinit)(SCREEN *);
     void   (*scexit)(SCREEN *);
-    int    (*twait)(struct DriverTCB*,int,int,int* EVENTLIST_2nd(_nc_eventlist*));
-    int    (*read)(struct DriverTCB*,int*);
-    int    (*nap)(struct DriverTCB*,int);
-    int    (*kpad)(struct DriverTCB*, bool);
-    int    (*kyOk)(struct DriverTCB*, int, bool);
+    int    (*twait)(struct DriverTCB*, int, int, int* EVENTLIST_2nd(_nc_eventlist*));
+    int    (*read)(struct DriverTCB*, int*);
+    int    (*nap)(struct DriverTCB*, int);
+    int    (*kpad)(struct DriverTCB*, int);
+    int    (*kyOk)(struct DriverTCB*, int, int);
     bool   (*kyExist)(struct DriverTCB*, int);
 } TERM_DRIVER;
 
@@ -2225,7 +2226,7 @@ extern NCURSES_EXPORT(int)      TINFO_MVCUR(SCREEN*, int, int, int, int);
  */
 #ifdef USE_TERM_DRIVER
 extern NCURSES_EXPORT(void)   _nc_get_screensize(SCREEN *, TERMINAL *, int *, int *);
-extern NCURSES_EXPORT(int)    _nc_setupterm_ex(TERMINAL **, NCURSES_CONST char *, int , int *, bool);
+extern NCURSES_EXPORT(int)    _nc_setupterm_ex(TERMINAL **, NCURSES_CONST char *, int , int *, int);
 #define TINFO_GET_SIZE(sp, tp, lp, cp) \
        _nc_get_screensize(sp, tp, lp, cp)
 #define TINFO_SET_CURTERM(sp, tp) \
@@ -2301,12 +2302,12 @@ extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_init)(SCREEN*,const char
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_restore)(SCREEN*, const char*);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scrolln)(SCREEN*, int, int, int, int);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_set_tty_mode)(SCREEN*, TTY*);
-extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_setupscreen)(SCREEN**, int, int, FILE *, bool, int);
+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_setupscreen)(SCREEN**, int, int, FILE *, int, int);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tgetent)(SCREEN*,char*,const char *);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tigetnum)(SCREEN*,NCURSES_CONST char*);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_vid_attr)(SCREEN *, attr_t, short, void *);
 extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_vidputs)(SCREEN*,chtype,int(*) (SCREEN*, int));
-extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_do_color)(SCREEN*, short, short, bool, NCURSES_SP_OUTC);
+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_do_color)(SCREEN*, int, int, int, NCURSES_SP_OUTC);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_do_xmc_glitch)(SCREEN*, attr_t);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_flush)(SCREEN*);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_free_and_exit)(SCREEN*, int) GCC_NORETURN;
@@ -2322,7 +2323,7 @@ extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_screen_resume)(SCREEN*);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_screen_wrap)(SCREEN*);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_scroll_oldhash)(SCREEN*, int n, int top, int bot);
 extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_scroll_optimize)(SCREEN*);
-extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_set_buffer)(SCREEN*, FILE *, bool);
+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_set_buffer)(SCREEN*, FILE *, int);
 
 extern NCURSES_EXPORT(void)     _nc_cookie_init(SCREEN *sp);
 
index 4d1b53a5bd9a12252f422fda43ff5f655dadb916..20c94a639b9ab96e74a395eee59e812f87e253af 100755 (executable)
@@ -1,6 +1,6 @@
 #!/bin/sh
 ##############################################################################
-# Copyright (c) 2007-2009,2010 Free Software Foundation, Inc.                #
+# Copyright (c) 2007-2010,2011 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 "Software"), #
@@ -26,7 +26,7 @@
 # use or other dealings in this Software without prior written               #
 # authorization.                                                             #
 ##############################################################################
-# $Id: MKcaptab.sh,v 1.13 2010/12/25 23:43:58 tom Exp $
+# $Id: MKcaptab.sh,v 1.14 2011/10/22 16:34:50 tom Exp $
 AWK=${1-awk}
 OPT1=${2-0}
 OPT2=${3-tinfo/MKcaptab.awk}
@@ -99,12 +99,12 @@ static const struct alias *
 _nc_build_alias(struct alias **actual,
                const alias_table_data *source,
                const char *strings,
-               unsigned tablesize)
+               size_t tablesize)
 {
     if (*actual == 0) {
        *actual = typeCalloc(struct alias, tablesize + 1);
        if (*actual != 0) {
-           unsigned n;
+           size_t n;
            for (n = 0; n < tablesize; ++n) {
                add_alias(from);
                add_alias(to);
@@ -178,7 +178,7 @@ tcap_hash(const char *string)
 static int
 compare_tcap_names(const char *a, const char *b)
 {
-    return !strncmp(a, b, TCAP_LEN);
+    return !strncmp(a, b, (size_t) TCAP_LEN);
 }
 
 static int
index 506fb386d208d914fca43142019317f593285693..9d70634e9c0c6b2d2cfe2756df0006d6abdddf48 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2008,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -47,7 +47,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: alloc_entry.c,v 1.51 2010/12/25 23:06:01 tom Exp $")
+MODULE_ID("$Id: alloc_entry.c,v 1.52 2011/10/22 16:34:50 tom Exp $")
 
 #define ABSENT_OFFSET    -1
 #define CANCELLED_OFFSET -2
@@ -73,7 +73,7 @@ _nc_init_entry(TERMTYPE *const tp)
 #endif
 
     if (stringbuf == 0)
-       stringbuf = (char *) malloc(MAX_STRTAB);
+       stringbuf = (char *) malloc((size_t) MAX_STRTAB);
 
 #if NCURSES_XNAMES
     tp->num_Booleans = BOOLCOUNT;
index f2575f8ac2ddff9e2314296721c4d24d7037ef33..cc57db31290ebb998a66705fb992c3b6df698abe 100644 (file)
@@ -93,7 +93,7 @@
 #include <ctype.h>
 #include <tic.h>
 
-MODULE_ID("$Id: captoinfo.c,v 1.69 2011/07/30 21:33:42 tom Exp $")
+MODULE_ID("$Id: captoinfo.c,v 1.70 2011/10/22 14:59:34 tom Exp $")
 
 #define MAX_PUSHED     16      /* max # args we can push onto the stack */
 
@@ -743,15 +743,15 @@ _nc_infotocap(const char *cap GCC_UNUSED, const char *str, int const parameteriz
            bufptr = save_tc_char(bufptr, c1);
        }
        /* FIXME: this "works" for 'delta' */
-       else if (strncmp(str, "%{2}%*%-", 8) == 0) {
+       else if (strncmp(str, "%{2}%*%-", (size_t) 8) == 0) {
            str += 7;
            bufptr = save_string(bufptr, "%D");
-       } else if (strncmp(str, "%{96}%^", 7) == 0) {
+       } else if (strncmp(str, "%{96}%^", (size_t) 7) == 0) {
            str += 6;
            if (saw_m++ == 0) {
                bufptr = save_string(bufptr, "%n");
            }
-       } else if (strncmp(str, "%{127}%^", 8) == 0) {
+       } else if (strncmp(str, "%{127}%^", (size_t) 8) == 0) {
            str += 7;
            if (saw_n++ == 0) {
                bufptr = save_string(bufptr, "%m");
index 24b85675795f352008059fade9157b96ffd7d01d..b6a2c4e5c4d09d271f9bc8657ce7fb4abccc4cba 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2007,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -41,7 +41,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: comp_error.c,v 1.32 2011/07/29 00:40:41 tom Exp $")
+MODULE_ID("$Id: comp_error.c,v 1.33 2011/10/22 16:34:50 tom Exp $")
 
 NCURSES_EXPORT_VAR(bool) _nc_suppress_warnings = FALSE;
 NCURSES_EXPORT_VAR(int) _nc_curr_line = 0; /* current line # in input */
@@ -71,7 +71,7 @@ _nc_set_type(const char *const name)
     if (TermType != 0) {
        TermType[0] = '\0';
        if (name)
-           strncat(TermType, name, MAX_NAME_SIZE);
+           strncat(TermType, name, (size_t) MAX_NAME_SIZE);
     }
 }
 
index a1f9f4a877fb634cec5bc3a04fe48a9b97e7ce43..ed2cfbd4189b8ec29a0c67284bbff00be9f7cc23 100644 (file)
@@ -47,7 +47,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: comp_parse.c,v 1.77 2011/10/01 22:43:51 tom Exp $")
+MODULE_ID("$Id: comp_parse.c,v 1.78 2011/10/22 16:19:19 tom Exp $")
 
 static void sanity_check2(TERMTYPE *, bool);
 NCURSES_IMPEXP void NCURSES_API(*_nc_check_termtype2) (TERMTYPE *, bool) = sanity_check2;
@@ -56,7 +56,7 @@ NCURSES_IMPEXP void NCURSES_API(*_nc_check_termtype2) (TERMTYPE *, bool) = sanit
 static void sanity_check(TERMTYPE *);
 NCURSES_IMPEXP void NCURSES_API(*_nc_check_termtype) (TERMTYPE *) = sanity_check;
 
-static void fixup_acsc(TERMTYPE *, bool);
+static void fixup_acsc(TERMTYPE *, int);
 
 static void
 enqueue(ENTRY * ep)
@@ -495,7 +495,7 @@ _nc_resolve_uses(bool fullresolve)
 #define CUR tp->
 
 static void
-fixup_acsc(TERMTYPE *tp, bool literal)
+fixup_acsc(TERMTYPE *tp, int literal)
 {
     if (!literal) {
        if (acs_chars == 0
index ef604026a151c8173d2c1cd99b59273822df447a..17c42df59aa91d5d794310f5cab22a8a7156f836 100644 (file)
@@ -50,7 +50,7 @@
 #include <ctype.h>
 #include <tic.h>
 
-MODULE_ID("$Id: comp_scan.c,v 1.93 2011/08/20 21:19:40 tom Exp $")
+MODULE_ID("$Id: comp_scan.c,v 1.94 2011/10/22 15:46:43 tom Exp $")
 
 /*
  * Maximum length of string capability we'll accept before raising an error.
@@ -257,12 +257,12 @@ next_char(void)
 }
 
 static void
-push_back(char c)
+push_back(int c)
 /* push a character back onto the input stream */
 {
     if (bufptr == bufstart)
        _nc_syserr_abort("Can't backspace off beginning of line");
-    *--bufptr = c;
+    *--bufptr = (char) c;
     _nc_curr_col--;
 }
 
@@ -782,7 +782,7 @@ _nc_trans_string(char *ptr, char *last)
                                /* allow the digit; it'll do less harm */
                            }
                        } else {
-                           push_back((char) c);
+                           push_back(c);
                            break;
                        }
                    }
@@ -878,7 +878,7 @@ _nc_trans_string(char *ptr, char *last)
 
        if (!ignored) {
            if (_nc_curr_col <= 1) {
-               push_back((char) c);
+               push_back(c);
                c = '\n';
                break;
            }
index 036a61b2b6aec1fc5d0db1ae3d1990be676bf9a9..30981e5c8058b4002103a897429dfd183d46072d 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2006-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 2006-2010,2011 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            *
@@ -37,7 +37,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: entries.c,v 1.18 2011/10/08 20:32:26 tom Exp $")
+MODULE_ID("$Id: entries.c,v 1.19 2011/10/22 16:34:50 tom Exp $")
 
 /****************************************************************************
  *
@@ -141,7 +141,7 @@ _nc_leaks_tinfo(void)
 
 #ifdef TRACE
     trace(0);
-    _nc_trace_buf(-1, 0);
+    _nc_trace_buf(-1, (size_t) 0);
 #endif
 
 #endif /* NO_LEAKS */
index 654bf940aa1f9fc8940dc13798a02456d2419772..e64b27587fac78d7febefcbf0599abe58c693c80 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2009,2011 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            *
@@ -46,7 +46,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_options.c,v 1.71 2009/10/24 21:56:15 tom Exp $")
+MODULE_ID("$Id: lib_options.c,v 1.72 2011/10/22 16:31:35 tom Exp $")
 
 NCURSES_EXPORT(int)
 idlok(WINDOW *win, bool flag)
@@ -324,7 +324,7 @@ _nc_putp_flush(const char *name, const char *value)
  * the terminal state _before_ switching modes.
  */
 NCURSES_EXPORT(int)
-_nc_keypad(SCREEN *sp, bool flag)
+_nc_keypad(SCREEN *sp, int flag)
 {
     int rc = ERR;
 
index c7bd3a62fa87b1e3794890f93b8a4fb0c25b0404..e30ceae87226ca1b698931b9777cdde77dd5442b 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -39,7 +39,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_print.c,v 1.20 2010/06/05 22:18:35 tom Exp $")
+MODULE_ID("$Id: lib_print.c,v 1.21 2011/10/22 16:34:50 tom Exp $")
 
 NCURSES_EXPORT(int)
 NCURSES_SP_NAME(mcprint) (NCURSES_SP_DCLx char *data, int len)
@@ -77,7 +77,7 @@ NCURSES_SP_NAME(mcprint) (NCURSES_SP_DCLx char *data, int len)
     }
 
     (void) strcpy(mybuf, switchon);
-    memcpy(mybuf + onsize, data, (unsigned) len);
+    memcpy(mybuf + onsize, data, (size_t) len);
     if (offsize)
        (void) strcpy(mybuf + onsize + len, prtr_off);
 
index 9bfe17a861a64c078dbb55124328dc8bfc6fece9..de4cb459728ab908f9393cdf6125b9dc30c94a1e 100644 (file)
@@ -47,7 +47,7 @@
 #include <locale.h>
 #endif
 
-MODULE_ID("$Id: lib_setup.c,v 1.141 2011/08/13 16:07:22 tom Exp $")
+MODULE_ID("$Id: lib_setup.c,v 1.142 2011/10/22 16:13:06 tom Exp $")
 
 /****************************************************************************
  *
@@ -449,7 +449,7 @@ _nc_setup_tinfo(const char *const tn, TERMTYPE *const tp)
 **     and substitute it in for the prototype given in 'command_character'.
 */
 void
-_nc_tinfo_cmdch(TERMINAL * termp, char proto)
+_nc_tinfo_cmdch(TERMINAL * termp, int proto)
 {
     unsigned i;
     char CC;
@@ -464,7 +464,7 @@ _nc_tinfo_cmdch(TERMINAL * termp, char proto)
        CC = *tmp;
        for_each_string(i, &(termp->type)) {
            for (tmp = termp->type.Strings[i]; tmp && *tmp; tmp++) {
-               if (*tmp == proto)
+               if (UChar(*tmp) == proto)
                    *tmp = CC;
            }
        }
@@ -560,7 +560,7 @@ TINFO_SETUP_TERM(TERMINAL ** tp,
                 NCURSES_CONST char *tname,
                 int Filedes,
                 int *errret,
-                bool reuse)
+                int reuse)
 {
 #ifdef USE_TERM_DRIVER
     TERMINAL_CONTROL_BLOCK *TCB = 0;
@@ -680,7 +680,7 @@ TINFO_SETUP_TERM(TERMINAL ** tp,
            }
        }
 #if !USE_REENTRANT
-       strncpy(ttytype, termp->type.term_names, NAMESIZE - 1);
+       strncpy(ttytype, termp->type.term_names, (size_t) (NAMESIZE - 1));
        ttytype[NAMESIZE - 1] = '\0';
 #endif
 
@@ -690,7 +690,7 @@ TINFO_SETUP_TERM(TERMINAL ** tp,
        set_curterm(termp);
 
        if (command_character)
-           _nc_tinfo_cmdch(termp, *command_character);
+           _nc_tinfo_cmdch(termp, UChar(*command_character));
 
        /*
         * If an application calls setupterm() rather than initscr() or
@@ -789,7 +789,7 @@ NCURSES_EXPORT(int)
 _nc_setupterm(NCURSES_CONST char *tname,
              int Filedes,
              int *errret,
-             bool reuse)
+             int reuse)
 {
     int res;
     TERMINAL *termp;
index 0349c9408a8eb04b05616d265d27df6534d9dc98..4d42307519f1fbe0f5d47f7404f037908c703ec2 100644 (file)
@@ -48,7 +48,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_termcap.c,v 1.75 2011/09/26 22:44:30 tom Exp $")
+MODULE_ID("$Id: lib_termcap.c,v 1.76 2011/10/22 17:12:41 tom Exp $")
 
 NCURSES_EXPORT_VAR(char *) UP = 0;
 NCURSES_EXPORT_VAR(char *) BC = 0;
@@ -203,10 +203,11 @@ static bool
 same_tcname(const char *a, const char *b)
 {
     fprintf(stderr, "compare(%s,%s)\n", a, b);
-    return !strncmp(a, b, 2);
+    return !strncmp(a, b, (size_t) 2);
 }
+
 #else
-#define same_tcname(a,b) !strncmp(a,b,2)
+#define same_tcname(a,b) !strncmp(a, b, (size_t) 2)
 #endif
 
 /***************************************************************************
index b1d79248d0fdbfb03914a1ffb3fb0d00893633be..53205d1711bf06fb86c563edc4433e959ee9e995 100644 (file)
@@ -42,7 +42,7 @@
 #include <ctype.h>
 #include <tic.h>
 
-MODULE_ID("$Id: lib_tparm.c,v 1.83 2011/05/21 18:11:56 tom Exp $")
+MODULE_ID("$Id: lib_tparm.c,v 1.84 2011/10/22 15:48:47 tom Exp $")
 
 /*
  *     char *
@@ -153,7 +153,7 @@ save_number(const char *fmt, int number, int len)
     if (len < 30)
        len = 30;               /* actually log10(MAX_INT)+1 */
 
-    get_space((unsigned) len + 1);
+    get_space((size_t) len + 1);
 
     (void) sprintf(TPS(out_buff) + TPS(out_used), fmt, number);
     TPS(out_used) += strlen(TPS(out_buff) + TPS(out_used));
@@ -164,7 +164,7 @@ save_char(int c)
 {
     if (c == 0)
        c = 0200;
-    get_space(1);
+    get_space((size_t) 1);
     TPS(out_buff)[TPS(out_used)++] = (char) c;
 }
 
@@ -450,7 +450,7 @@ _nc_tparm_analyze(const char *string, char *p_is_s[NUM_PARM], int *popcount)
 }
 
 static NCURSES_INLINE char *
-tparam_internal(bool use_TPARM_ARG, const char *string, va_list ap)
+tparam_internal(int use_TPARM_ARG, const char *string, va_list ap)
 {
     char *p_is_s[NUM_PARM];
     TPARM_ARG param[NUM_PARM];
@@ -757,7 +757,7 @@ tparam_internal(bool use_TPARM_ARG, const char *string, va_list ap)
        cp++;
     }                          /* endwhile (*cp) */
 
-    get_space(1);
+    get_space((size_t) 1);
     TPS(out_buff)[TPS(out_used)] = '\0';
 
     T((T_RETURN("%s"), _nc_visbuf(TPS(out_buff))));
index dc70f3e0b0b8226a0cf93eda39fccd9651a2cbf5..e37e7a13026184ff720a8973ec01e02789252daa 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -51,7 +51,7 @@
 #include <termcap.h>           /* ospeed */
 #include <tic.h>
 
-MODULE_ID("$Id: lib_tputs.c,v 1.81 2010/12/20 00:42:50 tom Exp $")
+MODULE_ID("$Id: lib_tputs.c,v 1.82 2011/10/22 16:34:50 tom Exp $")
 
 NCURSES_EXPORT_VAR(char) PC = 0;              /* used by termcap library */
 NCURSES_EXPORT_VAR(NCURSES_OSPEED) ospeed = 0;        /* used by termcap library */
@@ -145,7 +145,7 @@ NCURSES_SP_NAME(_nc_outch) (NCURSES_SP_DCLx int ch)
         * POSIX says write() is safe in a signal handler, but the
         * buffered I/O is not.
         */
-       if (write(fileno(NC_OUTPUT(SP_PARM)), &tmp, 1) == -1)
+       if (write(fileno(NC_OUTPUT(SP_PARM)), &tmp, (size_t) 1) == -1)
            rc = ERR;
     } else {
        if (putc(ch, NC_OUTPUT(SP_PARM)) == EOF)
index a7854e3fe604be840dbd885fe7281b3b5111640b..f44f7c77ff7e3d6762a7566db65b624dec4075d4 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2008,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -39,7 +39,7 @@
 #define USE_TERMLIB 1
 #include <build.priv.h>
 
-MODULE_ID("$Id: make_keys.c,v 1.19 2010/06/05 22:08:00 tom Exp $")
+MODULE_ID("$Id: make_keys.c,v 1.20 2011/10/22 16:34:50 tom Exp $")
 
 #include <names.c>
 
@@ -76,7 +76,7 @@ make_keys(FILE *ifp, FILE *ofp)
     unsigned maxlen = 16;
     int scanned;
 
-    while (fgets(buffer, sizeof(buffer), ifp) != 0) {
+    while (fgets(buffer, (int) sizeof(buffer), ifp) != 0) {
        if (*buffer == '#')
            continue;
 
index a237d60dbfbfbe6fbbccba0f85bfac84a6ea0197..44a42d6f2c34ac53f5507c52cc1a2153edd79257 100644 (file)
@@ -41,7 +41,7 @@
 
 #include <tic.h>
 
-MODULE_ID("$Id: read_entry.c,v 1.116 2011/09/27 00:35:20 tom Exp $")
+MODULE_ID("$Id: read_entry.c,v 1.117 2011/10/22 15:30:24 tom Exp $")
 
 #define TYPE_CALLOC(type,elts) typeCalloc(type, (unsigned)(elts))
 
@@ -99,7 +99,7 @@ fake_read(char *src, int *offset, int limit, char *dst, unsigned want)
     if (have > 0) {
        if ((int) want > have)
            want = (unsigned) have;
-       memcpy(dst, src + *offset, want);
+       memcpy(dst, src + *offset, (size_t) want);
        *offset += (int) want;
     } else {
        want = 0;
@@ -107,10 +107,10 @@ fake_read(char *src, int *offset, int limit, char *dst, unsigned want)
     return (int) want;
 }
 
-#define Read(buf, count) fake_read(buffer, &offset, limit, buf, count)
+#define Read(buf, count) fake_read(buffer, &offset, limit, buf, (unsigned) count)
 
 #define read_shorts(buf, count) \
-       (Read(buf, (unsigned) (count)*2) == (int) (count)*2)
+       (Read(buf, (count)*2) == (int) (count)*2)
 
 #define even_boundary(value) \
     if ((value) % 2 != 0) Read(buf, 1)
@@ -175,7 +175,7 @@ _nc_read_termtype(TERMTYPE *ptr, char *buffer, int limit)
     ptr->str_table = string_table;
     ptr->term_names = string_table;
     if ((have = (unsigned) Read(ptr->term_names, want)) != want) {
-       memset(ptr->term_names + have, 0, want - have);
+       memset(ptr->term_names + have, 0, (size_t) (want - have));
     }
     ptr->term_names[want] = '\0';
     string_table += (want + 1);
index a2e2660c8664909c0f60b1b0f835c8ae36a2156d..75b952fb33a248c0a95b8de42f88cc12b72faf86 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -42,7 +42,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: setbuf.c,v 1.16 2010/08/28 21:08:31 tom Exp $")
+MODULE_ID("$Id: setbuf.c,v 1.17 2011/10/22 16:34:50 tom Exp $")
 
 /*
  * If the output file descriptor is connected to a tty (the typical case) it
@@ -100,7 +100,7 @@ MODULE_ID("$Id: setbuf.c,v 1.16 2010/08/28 21:08:31 tom Exp $")
  * buffer.  So we disable this by default (there may yet be a workaround).
  */
 NCURSES_EXPORT(void)
-NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered)
+NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, int buffered)
 {
     int Cols;
     int Lines;
@@ -149,7 +149,7 @@ NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered)
 #ifdef SETVBUF_REVERSED                /* pre-svr3? */
        (void) setvbuf(ofp, buf_ptr, buf_len, buf_len ? _IOFBF : _IOLBF);
 #else
-       (void) setvbuf(ofp, buf_ptr, buf_len ? _IOFBF : _IOLBF, buf_len);
+       (void) setvbuf(ofp, buf_ptr, buf_len ? _IOFBF : _IOLBF, (size_t) buf_len);
 #endif
 #elif HAVE_SETBUFFER
        (void) setbuffer(ofp, buf_ptr, (int) buf_len);
@@ -162,7 +162,7 @@ NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered)
 
 #if NCURSES_SP_FUNCS
 NCURSES_EXPORT(void)
-_nc_set_buffer(FILE *ofp, bool buffered)
+_nc_set_buffer(FILE *ofp, int buffered)
 {
     NCURSES_SP_NAME(_nc_set_buffer) (CURRENT_SCREEN, ofp, buffered);
 }
index 589df2e036a3beb788a5a026a784ced320921d97..e97eff6fc8dfb2cc1a3b3ab1246e0176ada4772f 100644 (file)
@@ -50,7 +50,7 @@
 # endif
 #endif
 
-MODULE_ID("$Id: tinfo_driver.c,v 1.15 2011/08/13 16:11:15 tom Exp $")
+MODULE_ID("$Id: tinfo_driver.c,v 1.16 2011/10/22 17:50:33 tom Exp $")
 
 /*
  * SCO defines TIOCGSIZE and the corresponding struct.  Other systems (SunOS,
@@ -145,7 +145,7 @@ drv_CanHandle(TERMINAL_CONTROL_BLOCK * TCB, const char *tname, int *errret)
     }
     result = TRUE;
 #if !USE_REENTRANT
-    strncpy(ttytype, termp->type.term_names, NAMESIZE - 1);
+    strncpy(ttytype, termp->type.term_names, (size_t) NAMESIZE - 1);
     ttytype[NAMESIZE - 1] = '\0';
 #endif
 
@@ -173,7 +173,7 @@ drv_CanHandle(TERMINAL_CONTROL_BLOCK * TCB, const char *tname, int *errret)
 }
 
 static int
-drv_dobeepflash(TERMINAL_CONTROL_BLOCK * TCB, bool beepFlag)
+drv_dobeepflash(TERMINAL_CONTROL_BLOCK * TCB, int beepFlag)
 {
     SCREEN *sp;
     int res = ERR;
@@ -271,7 +271,7 @@ drv_defaultcolors(TERMINAL_CONTROL_BLOCK * TCB, int fg, int bg)
 
 static void
 drv_setcolor(TERMINAL_CONTROL_BLOCK * TCB,
-            bool fore,
+            int fore,
             int color,
             NCURSES_SP_OUTC outc)
 {
@@ -457,7 +457,7 @@ drv_setsize(TERMINAL_CONTROL_BLOCK * TCB, int l, int c)
 }
 
 static int
-drv_sgmode(TERMINAL_CONTROL_BLOCK * TCB, bool setFlag, TTY * buf)
+drv_sgmode(TERMINAL_CONTROL_BLOCK * TCB, int setFlag, TTY * buf)
 {
     SCREEN *sp = TCB->csp;
     TERMINAL *_term = (TERMINAL *) TCB;
@@ -491,7 +491,7 @@ drv_sgmode(TERMINAL_CONTROL_BLOCK * TCB, bool setFlag, TTY * buf)
 }
 
 static int
-drv_mode(TERMINAL_CONTROL_BLOCK * TCB, bool progFlag, bool defFlag)
+drv_mode(TERMINAL_CONTROL_BLOCK * TCB, int progFlag, int defFlag)
 {
     SCREEN *sp;
     TERMINAL *_term = (TERMINAL *) TCB;
@@ -622,7 +622,7 @@ drv_init(TERMINAL_CONTROL_BLOCK * TCB)
     trm = (TERMINAL *) TCB;
     sp = TCB->csp;
 
-    TCB->info.initcolor = initialize_color;
+    TCB->info.initcolor = VALID_STRING(initialize_color);
     TCB->info.canchange = can_change;
     TCB->info.hascolor = ((VALID_NUMERIC(max_colors) && VALID_NUMERIC(max_pairs)
                           && (((set_foreground != NULL)
@@ -659,7 +659,7 @@ drv_init(TERMINAL_CONTROL_BLOCK * TCB)
 #define InPalette(n)   ((n) >= 0 && (n) < MAX_PALETTE)
 
 static void
-drv_initpair(TERMINAL_CONTROL_BLOCK * TCB, short pair, short f, short b)
+drv_initpair(TERMINAL_CONTROL_BLOCK * TCB, int pair, int f, int b)
 {
     SCREEN *sp;
 
@@ -706,7 +706,7 @@ default_bg(SCREEN *sp)
 
 static void
 drv_initcolor(TERMINAL_CONTROL_BLOCK * TCB,
-             short color, short r, short g, short b)
+             int color, int r, int g, int b)
 {
     SCREEN *sp = TCB->csp;
 
@@ -720,9 +720,9 @@ drv_initcolor(TERMINAL_CONTROL_BLOCK * TCB,
 
 static void
 drv_do_color(TERMINAL_CONTROL_BLOCK * TCB,
-            short old_pair,
-            short pair,
-            bool reverse,
+            int old_pair,
+            int pair,
+            int reverse,
             NCURSES_SP_OUTC outc)
 {
     SCREEN *sp = TCB->csp;
@@ -893,7 +893,7 @@ drv_hwlabel(TERMINAL_CONTROL_BLOCK * TCB, int labnum, char *text)
 }
 
 static void
-drv_hwlabelOnOff(TERMINAL_CONTROL_BLOCK * TCB, bool OnFlag)
+drv_hwlabelOnOff(TERMINAL_CONTROL_BLOCK * TCB, int OnFlag)
 {
     SCREEN *sp = TCB->csp;
 
@@ -1170,7 +1170,7 @@ drv_read(TERMINAL_CONTROL_BLOCK * TCB, int *buf)
     if ((pthread_self) && (pthread_kill) && (pthread_equal))
        _nc_globals.read_thread = pthread_self();
 # endif
-    n = read(sp->_ifd, &c2, 1);
+    n = read(sp->_ifd, &c2, (size_t) 1);
 #if USE_PTHREADS_EINTR
     _nc_globals.read_thread = 0;
 #endif
@@ -1219,7 +1219,7 @@ __nc_putp_flush(SCREEN *sp, const char *name, const char *value)
 }
 
 static int
-drv_kpad(TERMINAL_CONTROL_BLOCK * TCB, bool flag)
+drv_kpad(TERMINAL_CONTROL_BLOCK * TCB, int flag)
 {
     int ret = ERR;
     SCREEN *sp;
@@ -1245,7 +1245,7 @@ drv_kpad(TERMINAL_CONTROL_BLOCK * TCB, bool flag)
 }
 
 static int
-drv_keyok(TERMINAL_CONTROL_BLOCK * TCB, int c, bool flag)
+drv_keyok(TERMINAL_CONTROL_BLOCK * TCB, int c, int flag)
 {
     SCREEN *sp;
     int code = ERR;
@@ -1258,7 +1258,8 @@ drv_keyok(TERMINAL_CONTROL_BLOCK * TCB, int c, bool flag)
     if (c >= 0) {
        unsigned ch = (unsigned) c;
        if (flag) {
-           while ((s = _nc_expand_try(sp->_key_ok, ch, &count, 0)) != 0
+           while ((s = _nc_expand_try(sp->_key_ok,
+                                      ch, &count, (size_t) 0)) != 0
                   && _nc_remove_key(&(sp->_key_ok), ch)) {
                code = _nc_add_to_try(&(sp->_keytry), s, ch);
                free(s);
@@ -1267,7 +1268,8 @@ drv_keyok(TERMINAL_CONTROL_BLOCK * TCB, int c, bool flag)
                    break;
            }
        } else {
-           while ((s = _nc_expand_try(sp->_keytry, ch, &count, 0)) != 0
+           while ((s = _nc_expand_try(sp->_keytry,
+                                      ch, &count, (size_t) 0)) != 0
                   && _nc_remove_key(&(sp->_keytry), ch)) {
                code = _nc_add_to_try(&(sp->_key_ok), s, ch);
                free(s);
index a14feedf282524db8944b0072d12fcb68c6cf7f8..3f6eebfcb33d9ae1f35fac5b5dfde2c3b591d776 100644 (file)
@@ -47,7 +47,7 @@
 #define TRACE_OUT(p)           /*nothing */
 #endif
 
-MODULE_ID("$Id: write_entry.c,v 1.80 2011/08/13 20:52:40 tom Exp $")
+MODULE_ID("$Id: write_entry.c,v 1.81 2011/10/22 15:33:37 tom Exp $")
 
 static int total_written;
 
@@ -70,7 +70,7 @@ write_file(char *filename, TERMTYPE *tp)
     DEBUG(1, ("Created %s", filename));
 
     if (write_object(tp, buffer, &offset, limit) == ERR
-       || fwrite(buffer, sizeof(char), offset, fp) != offset) {
+       || fwrite(buffer, sizeof(char), (size_t) offset, fp) != offset) {
        _nc_syserr_abort("error writing %s/%s", _nc_tic_dir(0), filename);
     }
 
@@ -109,7 +109,7 @@ check_writeable(int code)
 #endif /* !USE_HASHED_DB */
 
 static int
-make_db_path(char *dst, const char *src, unsigned limit)
+make_db_path(char *dst, const char *src, size_t limit)
 {
     int rc = -1;
     const char *top = _nc_tic_dir(0);
@@ -131,9 +131,9 @@ make_db_path(char *dst, const char *src, unsigned limit)
            rc = -1;
        } else {
            static const char suffix[] = DBM_SUFFIX;
-           unsigned have = strlen(dst);
-           unsigned need = strlen(suffix);
-           if (have > need && strcmp(dst + have - need, suffix)) {
+           size_t have = strlen(dst);
+           size_t need = strlen(suffix);
+           if (have > need && strcmp(dst + (int) (have - need), suffix)) {
                if (have + need <= limit)
                    strcat(dst, suffix);
                else
@@ -484,7 +484,7 @@ fake_write(char *dst,
     return (want / size);
 }
 
-#define Write(buf, size, count) fake_write(buffer, offset, limit, (char *) buf, count, size)
+#define Write(buf, size, count) fake_write(buffer, offset, (size_t) limit, (char *) buf, (size_t) count, (size_t) size)
 
 #undef LITTLE_ENDIAN           /* BSD/OS defines this as a feature macro */
 #define HI(x)                  ((x) / 256)
@@ -699,7 +699,7 @@ write_object(TERMTYPE *tp, char *buffer, unsigned *offset, unsigned limit)
            return (ERR);
 
        nextfree = compute_offsets(tp->Strings + STRCOUNT,
-                                  tp->ext_Strings,
+                                  (size_t) tp->ext_Strings,
                                   offsets);
        TRACE_OUT(("after extended string capabilities, nextfree=%d", nextfree));
 
@@ -707,7 +707,7 @@ write_object(TERMTYPE *tp, char *buffer, unsigned *offset, unsigned limit)
            return (ERR);
 
        nextfree += compute_offsets(tp->ext_Names,
-                                   extcnt,
+                                   (size_t) extcnt,
                                    offsets + tp->ext_Strings);
        TRACE_OUT(("after extended capnames, nextfree=%d", nextfree));
        strmax = tp->ext_Strings + extcnt;
@@ -735,7 +735,7 @@ write_object(TERMTYPE *tp, char *buffer, unsigned *offset, unsigned limit)
 
        TRACE_OUT(("WRITE %d numbers @%d", tp->ext_Numbers, *offset));
        if (tp->ext_Numbers) {
-           convert_shorts(buf, tp->Numbers + NUMCOUNT, tp->ext_Numbers);
+           convert_shorts(buf, tp->Numbers + NUMCOUNT, (size_t) tp->ext_Numbers);
            if (Write(buf, 2, tp->ext_Numbers) != tp->ext_Numbers)
                return (ERR);
        }
index a726901d4a3a746a30ea4d3cb741a02a16c08ce3..7a8e6a9e752cd1003b2458ce78abe1a85a03dcf2 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -47,7 +47,7 @@
 
 #include <ctype.h>
 
-MODULE_ID("$Id: lib_trace.c,v 1.76 2010/12/19 01:21:19 tom Exp $")
+MODULE_ID("$Id: lib_trace.c,v 1.77 2011/10/22 16:34:50 tom Exp $")
 
 NCURSES_EXPORT_VAR(unsigned) _nc_tracing = 0; /* always define this */
 
@@ -121,7 +121,7 @@ trace(const unsigned int tracelevel)
         * end of each line.  This is useful in case the program dies. 
         */
 #if HAVE_SETVBUF               /* ANSI */
-       (void) setvbuf(TraceFP, (char *) 0, _IOLBF, 0);
+       (void) setvbuf(TraceFP, (char *) 0, _IOLBF, (size_t) 0);
 #elif HAVE_SETBUF /* POSIX */
        (void) setbuffer(TraceFP, (char *) 0);
 #endif
@@ -218,7 +218,7 @@ _tracef(const char *fmt,...)
 
 /* Trace 'bool' return-values */
 NCURSES_EXPORT(NCURSES_BOOL)
-_nc_retrace_bool(NCURSES_BOOL code)
+_nc_retrace_bool(int code)
 {
     T((T_RETURN("%s"), code ? "TRUE" : "FALSE"));
     return code;
@@ -226,7 +226,7 @@ _nc_retrace_bool(NCURSES_BOOL code)
 
 /* Trace 'char' return-values */
 NCURSES_EXPORT(char)
-_nc_retrace_char(char code)
+_nc_retrace_char(int code)
 {
     T((T_RETURN("%c"), code));
     return code;
index 6bbcc6230d114cac346d03ffb2cee79fa4b60003..8abc1c6a9a45962c58abf939611e02714e4ffb79 100644 (file)
@@ -43,7 +43,7 @@
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_traceatr.c,v 1.75 2011/05/28 22:56:56 tom Exp $")
+MODULE_ID("$Id: lib_traceatr.c,v 1.76 2011/10/22 15:39:21 tom Exp $")
 
 #define COLOR_OF(c) ((c < 0) ? "default" : (c > 7 ? color_of(c) : colors[c].name))
 
@@ -120,7 +120,7 @@ _traceattr2(int bufnum, chtype newmode)
     ;
     size_t n;
     char temp[80];
-    char *result = _nc_trace_buf(bufnum, BUFSIZ);
+    char *result = _nc_trace_buf(bufnum, (size_t) BUFSIZ);
 
     if (result != 0) {
        unsigned save_nc_tracing = _nc_tracing;
@@ -271,7 +271,7 @@ NCURSES_EXPORT(char *)
 _tracechtype2(int bufnum, chtype ch)
 {
     const char *found;
-    char *result = _nc_trace_buf(bufnum, BUFSIZ);
+    char *result = _nc_trace_buf(bufnum, (size_t) BUFSIZ);
 
     if (result != 0) {
        strcpy(result, l_brace);
@@ -311,7 +311,7 @@ _nc_retrace_chtype(chtype code)
 NCURSES_EXPORT(char *)
 _tracecchar_t2(int bufnum, const cchar_t *ch)
 {
-    char *result = _nc_trace_buf(bufnum, BUFSIZ);
+    char *result = _nc_trace_buf(bufnum, (size_t) BUFSIZ);
     attr_t attr;
     const char *found;
 
index 46baba4796b2e33108cf3d3ceaf41180cb6bf675..3768d098e8a76222a0ba4f59ea57b5482286d039 100644 (file)
@@ -35,7 +35,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: trace_buf.c,v 1.17 2011/01/22 19:48:16 tom Exp $")
+MODULE_ID("$Id: trace_buf.c,v 1.18 2011/10/22 15:46:06 tom Exp $")
 
 #ifdef TRACE
 
@@ -103,7 +103,7 @@ _nc_trace_buf(int bufnum, size_t want)
 NCURSES_EXPORT(char *)
 _nc_trace_bufcat(int bufnum, const char *value)
 {
-    char *buffer = _nc_trace_alloc(bufnum, 0);
+    char *buffer = _nc_trace_alloc(bufnum, (size_t) 0);
     if (buffer != 0) {
        size_t have = strlen(buffer);
 
index 66da4f4beca3cef79d9a9d5a9d47715d11ed031b..6922d3e2061662e19e78f24e8911e5ad20b085aa 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2001-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 2001-2010,2011 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            *
@@ -42,7 +42,7 @@
 #include <tic.h>
 #include <ctype.h>
 
-MODULE_ID("$Id: visbuf.c,v 1.37 2010/05/29 18:51:41 tom Exp $")
+MODULE_ID("$Id: visbuf.c,v 1.38 2011/10/22 16:34:50 tom Exp $")
 
 #define NUM_VISBUFS 4
 
@@ -261,7 +261,7 @@ _nc_viswibuf(const wint_t *buf)
 NCURSES_EXPORT(const char *)
 _nc_viscbuf2(int bufnum, const NCURSES_CH_T * buf, int len)
 {
-    char *result = _nc_trace_buf(bufnum, BUFSIZ);
+    char *result = _nc_trace_buf(bufnum, (size_t) BUFSIZ);
     int first;
     const char *found;
 
index b670e1b9691f36c6531d527a3077cd078b34632e..4a723865a4fdb0d425c3d67efd7bbe0050621865 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
@@ -73,7 +73,7 @@ AUTHOR
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: hashmap.c,v 1.62 2010/04/24 23:46:07 tom Exp $")
+MODULE_ID("$Id: hashmap.c,v 1.63 2011/10/22 16:34:50 tom Exp $")
 
 #ifdef HASHDEBUG
 
@@ -163,7 +163,7 @@ update_cost_from_blank(SCREEN *sp, NCURSES_CH_T * to)
  * effective. 'blank' indicates whether the line 'to' would become blank.
  */
 static NCURSES_INLINE bool
-cost_effective(SCREEN *sp, const int from, const int to, const bool blank)
+cost_effective(SCREEN *sp, const int from, const int to, const int blank)
 {
     int new_from;
 
index ad41f8dd72d8e8a5a05be1a0f895f38db466fd50..8de26c4f6a80800937e550f83f8f34acc78b5b5d 100644 (file)
 #define CUR SP_TERMTYPE
 #endif
 
-MODULE_ID("$Id: lib_mvcur.c,v 1.126 2011/01/22 19:48:21 tom Exp $")
+MODULE_ID("$Id: lib_mvcur.c,v 1.127 2011/10/22 16:09:52 tom Exp $")
 
 #define WANT_CHAR(sp, y, x) NewScreen(sp)->_line[y].text[x]    /* desired state */
 
@@ -549,7 +549,7 @@ relative_move(NCURSES_SP_DCLx
              int from_x,
              int to_y,
              int to_x,
-             bool ovw)
+             int ovw)
 /* move via local motions (cuu/cuu1/cud/cud1/cub1/cub/cuf1/cuf/vpa/hpa) */
 {
     string_desc save;
@@ -770,7 +770,7 @@ relative_move(NCURSES_SP_DCLx
  */
 
 static NCURSES_INLINE int
-onscreen_mvcur(NCURSES_SP_DCLx int yold, int xold, int ynew, int xnew, bool ovw)
+onscreen_mvcur(NCURSES_SP_DCLx int yold, int xold, int ynew, int xnew, int ovw)
 /* onscreen move from (yold, xold) to (ynew, xnew) */
 {
     string_desc result;
index 583ee0fdd5053d2fd06aa9375694ca092199870a..36043f8a2b39aeb41d56faf85e06570e3a0e70b5 100644 (file)
@@ -42,7 +42,7 @@
 
 #include <SigAction.h>
 
-MODULE_ID("$Id: lib_tstp.c,v 1.44 2011/06/25 21:22:16 tom Exp $")
+MODULE_ID("$Id: lib_tstp.c,v 1.45 2011/10/22 15:37:42 tom Exp $")
 
 #if defined(SIGTSTP) && (HAVE_SIGACTION || HAVE_SIGVEC)
 #define USE_SIGTSTP 1
@@ -363,7 +363,7 @@ CatchIfDefault(int sig, RETSIGTYPE (*handler) (int))
  * the caller later changes its mind, but that doesn't seem correct.
  */
 NCURSES_EXPORT(void)
-_nc_signal_handler(bool enable)
+_nc_signal_handler(int enable)
 {
     T((T_CALLED("_nc_signal_handler(%d)"), enable));
 #if USE_SIGTSTP                        /* Xenix 2.x doesn't have SIGTSTP, for example */
index 329ec29a019ffdfaecc9118f956176793e6c961b..023ba70b799d303dcdc8b6d381335d87d7e94102 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 1998-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 1998-2010,2011 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            *
 #endif
 #undef CUR
 
-MODULE_ID("$Id: lib_twait.c,v 1.61 2010/12/25 23:43:58 tom Exp $")
+MODULE_ID("$Id: lib_twait.c,v 1.62 2011/10/22 16:34:50 tom Exp $")
 
 static long
-_nc_gettime(TimeType * t0, bool first)
+_nc_gettime(TimeType * t0, int first)
 {
     long res;
 
@@ -247,7 +247,7 @@ _nc_timed_wait(SCREEN *sp MAYBE_UNUSED,
     }
 #endif
 
-    result = poll(fds, (unsigned) count, milliseconds);
+    result = poll(fds, (size_t) count, milliseconds);
 
 #ifdef NCURSES_WGETCH_EVENTS
     if ((mode & TW_EVENT) && evl) {
index 2dc93830ce95664612c4a9048b93c2faf4219ca8..c708ca6033a608805cc6f3a7dfc6aa88e2397a1a 100644 (file)
@@ -82,7 +82,7 @@
 
 #include <ctype.h>
 
-MODULE_ID("$Id: tty_update.c,v 1.265 2011/05/28 21:51:20 tom Exp $")
+MODULE_ID("$Id: tty_update.c,v 1.267 2011/10/22 17:30:14 tom Exp $")
 
 /*
  * This define controls the line-breakout optimization.  Every once in a
@@ -342,7 +342,7 @@ check_pending(NCURSES_SP_DCL0)
        struct pollfd fds[1];
        fds[0].fd = SP_PARM->_checkfd;
        fds[0].events = POLLIN;
-       if (poll(fds, 1, 0) > 0) {
+       if (poll(fds, (size_t) 1, 0) > 0) {
            have_pending = TRUE;
        }
 #elif defined(__BEOS__)
@@ -1079,7 +1079,7 @@ ClrUpdate(NCURSES_SP_DCL0)
 */
 
 static void
-ClrToEOL(NCURSES_SP_DCLx NCURSES_CH_T blank, bool needclear)
+ClrToEOL(NCURSES_SP_DCLx NCURSES_CH_T blank, int needclear)
 {
     int j;
 
index 0a1fe82f31f3b6ddb0269758106915bbe1a12b46..ac1b8ecac797b6426f211342ff1dde7f3b788dfc 100644 (file)
@@ -35,7 +35,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_cchar.c,v 1.23 2011/07/23 21:31:51 David.Benjamin Exp $")
+MODULE_ID("$Id: lib_cchar.c,v 1.24 2011/10/22 15:52:36 tom Exp $")
 
 /* 
  * The SuSv2 description leaves some room for interpretation.  We'll assume wch
@@ -111,7 +111,7 @@ getcchar(const cchar_t *wcval,
                      opts));
 
     if (opts == NULL && wcval != NULL) {
-       len = ((wp = wmemchr(wcval->chars, L'\0', CCHARW_MAX))
+       len = ((wp = wmemchr(wcval->chars, L'\0', (size_t) CCHARW_MAX))
               ? (int) (wp - wcval->chars)
               : CCHARW_MAX);
 
@@ -126,7 +126,7 @@ getcchar(const cchar_t *wcval,
        } else if (len >= 0) {
            *attrs = AttrOf(*wcval) & A_ATTRIBUTES;
            *color_pair = (short) GetPair(*wcval);
-           wmemcpy(wch, wcval->chars, (unsigned) len);
+           wmemcpy(wch, wcval->chars, (size_t) len);
            wch[len] = L'\0';
            code = OK;
        }
index 0b450211b2c3255c385b054e3099f483f88daf02..27cdae0c1fd8003d950a03be9677b9f5bf8d0954 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2002-2008,2009 Free Software Foundation, Inc.              *
+ * Copyright (c) 2002-2009,2011 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            *
@@ -39,7 +39,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_get_wstr.c,v 1.12 2009/10/24 22:38:11 tom Exp $")
+MODULE_ID("$Id: lib_get_wstr.c,v 1.13 2011/10/22 16:31:35 tom Exp $")
 
 static int
 wadd_wint(WINDOW *win, wint_t *src)
@@ -49,7 +49,7 @@ wadd_wint(WINDOW *win, wint_t *src)
 
     wch[0] = (wchar_t) (*src);
     wch[1] = 0;
-    setcchar(&tmp, wch, A_NORMAL, 0, NULL);
+    setcchar(&tmp, wch, A_NORMAL, (short) 0, NULL);
     return wadd_wch(win, &tmp);
 }
 
@@ -58,7 +58,7 @@ wadd_wint(WINDOW *win, wint_t *src)
  * or other character, and handles reverse wraparound.
  */
 static wint_t *
-WipeOut(WINDOW *win, int y, int x, wint_t *first, wint_t *last, bool echoed)
+WipeOut(WINDOW *win, int y, int x, wint_t *first, wint_t *last, int echoed)
 {
     if (last > first) {
        *--last = '\0';
index 1eee8a3ec016b01981783d7cdcc976f9e52cf17c..2aa71a50663952f301e277ef28eb8c9710c5bbf3 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2002-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 2002-2010,2011 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            *
@@ -39,7 +39,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_ins_wch.c,v 1.16 2010/12/19 01:34:04 tom Exp $")
+MODULE_ID("$Id: lib_ins_wch.c,v 1.17 2011/10/22 16:34:50 tom Exp $")
 
 /*
  * Insert the given character, updating the current location to simplify
@@ -132,7 +132,7 @@ wins_nwstr(WINDOW *win, const wchar_t *wstr, int n)
                    (void) setcchar(&tmp_cchar,
                                    &tmp_wchar,
                                    WA_NORMAL,
-                                   0,
+                                   (short) 0,
                                    (void *) 0);
                    code = _nc_insert_wch(win, &tmp_cchar);
                } else {
index c76c0f840ed09b42d1d0674fd55543c81aad7736..89275567557be5c6a3e24ec60c1da0bef9bb9c80 100644 (file)
@@ -40,7 +40,7 @@
 #include <wctype.h>
 #endif
 
-MODULE_ID("$Id: lib_slk_wset.c,v 1.12 2011/05/28 22:46:34 tom Exp $")
+MODULE_ID("$Id: lib_slk_wset.c,v 1.13 2011/10/22 15:52:20 tom Exp $")
 
 NCURSES_EXPORT(int)
 slk_wset(int i, const wchar_t *astr, int format)
@@ -56,7 +56,7 @@ slk_wset(int i, const wchar_t *astr, int format)
     if (astr != 0) {
        init_mb(state);
        str = astr;
-       if ((arglen = wcsrtombs(NULL, &str, 0, &state)) != (size_t) -1) {
+       if ((arglen = wcsrtombs(NULL, &str, (size_t) 0, &state)) != (size_t) -1) {
            if ((mystr = (char *) _nc_doalloc(0, arglen + 1)) != 0) {
                str = astr;
                if (wcsrtombs(mystr, &str, arglen, &state) != (size_t) -1) {
index 7a626a9eee8487dbc9d03400aed8327b84d0ffb8..d5ae608e36eda4ce2e5831c6189072a13a552d69 100644 (file)
@@ -1,5 +1,5 @@
 /****************************************************************************
- * Copyright (c) 2002-2009,2010 Free Software Foundation, Inc.              *
+ * Copyright (c) 2002-2010,2011 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            *
@@ -39,7 +39,7 @@
 
 #include <curses.priv.h>
 
-MODULE_ID("$Id: lib_unget_wch.c,v 1.14 2010/07/24 11:35:21 tom Exp $")
+MODULE_ID("$Id: lib_unget_wch.c,v 1.15 2011/10/22 16:34:50 tom Exp $")
 
 /*
  * Wrapper for wcrtomb() which obtains the length needed for the given
@@ -55,7 +55,7 @@ _nc_wcrtomb(char *target, wchar_t source, mbstate_t * state)
        const wchar_t *tempp = temp;
        temp[0] = source;
        temp[1] = 0;
-       result = (int) wcsrtombs(NULL, &tempp, 0, state);
+       result = (int) wcsrtombs(NULL, &tempp, (size_t) 0, state);
     } else {
        result = (int) wcrtomb(target, source, state);
     }