mirror of
https://github.com/Aigor44/ncursesw-morphos.git
synced 2024-12-27 07:49:06 +08:00
ncurses 6.1 - patch 20180324
+ amend Scaled256() macro in test/picsmap.c to cover the full range 0..1000 (report by Roger Pau Monne). + add some checks in tracemunch for undefined variables.
This commit is contained in:
parent
b86393354b
commit
073e4446d2
7
NEWS
7
NEWS
@ -25,7 +25,7 @@
|
||||
-- sale, use or other dealings in this Software without prior written --
|
||||
-- authorization. --
|
||||
-------------------------------------------------------------------------------
|
||||
-- $Id: NEWS,v 1.3102 2018/03/17 19:47:51 tom Exp $
|
||||
-- $Id: NEWS,v 1.3105 2018/03/24 22:56:36 tom Exp $
|
||||
-------------------------------------------------------------------------------
|
||||
|
||||
This is a log of changes that ncurses has gone through since Zeyd started
|
||||
@ -45,6 +45,11 @@ 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.
|
||||
|
||||
20180324
|
||||
+ amend Scaled256() macro in test/picsmap.c to cover the full range
|
||||
0..1000 (report by Roger Pau Monne).
|
||||
+ add some checks in tracemunch for undefined variables.
|
||||
|
||||
20180317
|
||||
+ fix a check in infotocap which may not have detected a problem when
|
||||
it should have.
|
||||
|
4
dist.mk
4
dist.mk
@ -25,7 +25,7 @@
|
||||
# use or other dealings in this Software without prior written #
|
||||
# authorization. #
|
||||
##############################################################################
|
||||
# $Id: dist.mk,v 1.1215 2018/03/17 16:49:57 tom Exp $
|
||||
# $Id: dist.mk,v 1.1216 2018/03/22 08:41:45 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 = 6
|
||||
NCURSES_MINOR = 1
|
||||
NCURSES_PATCH = 20180317
|
||||
NCURSES_PATCH = 20180324
|
||||
|
||||
# We don't append the patch to the version, since this only applies to releases
|
||||
VERSION = $(NCURSES_MAJOR).$(NCURSES_MINOR)
|
||||
|
@ -1,8 +1,8 @@
|
||||
ncurses6 (6.1+20180317) unstable; urgency=low
|
||||
ncurses6 (6.1+20180324) unstable; urgency=low
|
||||
|
||||
* latest weekly patch
|
||||
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Sat, 17 Mar 2018 12:49:57 -0400
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Thu, 22 Mar 2018 04:41:45 -0400
|
||||
|
||||
ncurses6 (5.9-20131005) unstable; urgency=low
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
ncurses6 (6.1+20180317) unstable; urgency=low
|
||||
ncurses6 (6.1+20180324) unstable; urgency=low
|
||||
|
||||
* latest weekly patch
|
||||
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Sat, 17 Mar 2018 12:49:57 -0400
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Thu, 22 Mar 2018 04:41:45 -0400
|
||||
|
||||
ncurses6 (5.9-20131005) unstable; urgency=low
|
||||
|
||||
|
@ -1,8 +1,8 @@
|
||||
ncurses6 (6.1+20180317) unstable; urgency=low
|
||||
ncurses6 (6.1+20180324) unstable; urgency=low
|
||||
|
||||
* latest weekly patch
|
||||
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Sat, 17 Mar 2018 12:49:57 -0400
|
||||
-- Thomas E. Dickey <dickey@invisible-island.net> Thu, 22 Mar 2018 04:41:45 -0400
|
||||
|
||||
ncurses6 (5.9-20120608) unstable; urgency=low
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
; $Id: mingw-ncurses.nsi,v 1.262 2018/03/17 16:49:57 tom Exp $
|
||||
; $Id: mingw-ncurses.nsi,v 1.263 2018/03/22 08:41:45 tom Exp $
|
||||
|
||||
; TODO add examples
|
||||
; TODO bump ABI to 6
|
||||
@ -10,7 +10,7 @@
|
||||
!define VERSION_MAJOR "6"
|
||||
!define VERSION_MINOR "1"
|
||||
!define VERSION_YYYY "2018"
|
||||
!define VERSION_MMDD "0317"
|
||||
!define VERSION_MMDD "0324"
|
||||
!define VERSION_PATCH ${VERSION_YYYY}${VERSION_MMDD}
|
||||
|
||||
!define MY_ABI "5"
|
||||
|
@ -3,7 +3,7 @@
|
||||
Summary: shared libraries for terminal handling
|
||||
Name: mingw32-ncurses6
|
||||
Version: 6.1
|
||||
Release: 20180317
|
||||
Release: 20180324
|
||||
License: X11
|
||||
Group: Development/Libraries
|
||||
Source: ncurses-%{version}-%{release}.tgz
|
||||
|
@ -1,7 +1,7 @@
|
||||
Summary: shared libraries for terminal handling
|
||||
Name: ncurses6
|
||||
Version: 6.1
|
||||
Release: 20180317
|
||||
Release: 20180324
|
||||
License: X11
|
||||
Group: Development/Libraries
|
||||
Source: ncurses-%{version}-%{release}.tgz
|
||||
|
@ -26,7 +26,7 @@
|
||||
* authorization. *
|
||||
****************************************************************************/
|
||||
/*
|
||||
* $Id: picsmap.c,v 1.117 2018/02/12 09:57:31 tom Exp $
|
||||
* $Id: picsmap.c,v 1.118 2018/03/24 22:37:42 tom Exp $
|
||||
*
|
||||
* Author: Thomas E. Dickey
|
||||
*
|
||||
@ -71,10 +71,12 @@
|
||||
#define L_CURLY '{'
|
||||
#define R_CURLY '}'
|
||||
|
||||
#define MaxSCALE 1000 /* input curses ranges 0..1000 */
|
||||
#define MaxRGB 255 /* output color ranges 0..255 */
|
||||
#define okCOLOR(n) ((n) >= 0 && (n) < COLORS)
|
||||
#define okRGB(n) ((n) >= 0 && (n) <= 1000)
|
||||
#define Scaled256(n) (NCURSES_COLOR_T) (int)(((n) * 1000.0) / 256)
|
||||
#define ScaledColor(n) (NCURSES_COLOR_T) (int)(((n) * 1000.0) / scale)
|
||||
#define okSCALE(n) ((n) >= 0 && (n) <= MaxSCALE)
|
||||
#define Scaled256(n) (NCURSES_COLOR_T) (int)(((double)(n) * MaxSCALE) / 255)
|
||||
#define ScaledColor(n) (NCURSES_COLOR_T) (int)(((double)(n) * MaxSCALE) / scale)
|
||||
|
||||
#ifndef RGB_PATH
|
||||
#define RGB_PATH "/etc/X11/rgb.txt"
|
||||
@ -650,7 +652,7 @@ init_palette(const char *palette_file)
|
||||
if (data != 0) {
|
||||
int n;
|
||||
int red, green, blue;
|
||||
int scale = 1000;
|
||||
int scale = MaxSCALE;
|
||||
int c;
|
||||
for (n = 0; data[n] != 0; ++n) {
|
||||
if (sscanf(data[n], "scale:%d", &c) == 1) {
|
||||
@ -661,9 +663,9 @@ init_palette(const char *palette_file)
|
||||
&green,
|
||||
&blue) == 4
|
||||
&& okCOLOR(c)
|
||||
&& okRGB(red)
|
||||
&& okRGB(green)
|
||||
&& okRGB(blue)) {
|
||||
&& okSCALE(red)
|
||||
&& okSCALE(green)
|
||||
&& okSCALE(blue)) {
|
||||
/* *INDENT-EQLS* */
|
||||
all_colors[c].red = ScaledColor(red);
|
||||
all_colors[c].green = ScaledColor(green);
|
||||
@ -1043,7 +1045,7 @@ parse_xbm(char **data)
|
||||
if (isdigit(UChar(*s))) {
|
||||
long value = strtol(s, &t, 0);
|
||||
int b;
|
||||
if (t != s || value > 255 || value < 0) {
|
||||
if (t != s || value > MaxRGB || value < 0) {
|
||||
s = t;
|
||||
} else {
|
||||
state = -1;
|
||||
@ -1347,9 +1349,9 @@ parse_img(const char *filename)
|
||||
&check)) {
|
||||
if ((s - t) > 8) /* 6 hex digits vs 8 */
|
||||
check /= 256;
|
||||
if (r > 255 ||
|
||||
g > 255 ||
|
||||
b > 255 ||
|
||||
if (r > MaxRGB ||
|
||||
g > MaxRGB ||
|
||||
b > MaxRGB ||
|
||||
check != (unsigned) ((r << 16) | (g << 8) | b)) {
|
||||
okay = FALSE;
|
||||
break;
|
||||
|
@ -1,5 +1,5 @@
|
||||
#!/usr/bin/env perl
|
||||
# $Id: tracemunch,v 1.17 2017/12/23 17:51:31 tom Exp $
|
||||
# $Id: tracemunch,v 1.18 2018/03/22 08:50:15 tom Exp $
|
||||
##############################################################################
|
||||
# Copyright (c) 1998-2005,2017 Free Software Foundation, Inc. #
|
||||
# #
|
||||
@ -62,19 +62,19 @@ sub transaddr {
|
||||
$arg =~ s/\b$stdscr\b/stdscr/g if ($stdscr);
|
||||
foreach my $addr ( keys %scr_addr ) {
|
||||
$n = $scr_addr{$addr};
|
||||
$arg =~ s/\b$addr\b/screen$n/g;
|
||||
$arg =~ s/\b$addr\b/screen$n/g if ( defined $n );
|
||||
}
|
||||
foreach my $addr ( keys %thr_addr ) {
|
||||
$n = $thr_addr{$addr};
|
||||
$arg =~ s/\b$addr\b/thread$n/g;
|
||||
$arg =~ s/\b$addr\b/thread$n/g if ( defined $n );
|
||||
}
|
||||
foreach my $addr ( keys %try_addr ) {
|
||||
$n = $try_addr{$addr};
|
||||
$arg =~ s/\b$addr\b/tries_$n/g;
|
||||
$arg =~ s/\b$addr\b/tries_$n/g if ( defined $n );
|
||||
}
|
||||
foreach my $addr ( keys %win_addr ) {
|
||||
$n = $win_addr{$addr};
|
||||
$arg =~ s/\b$addr\b/window$n/g;
|
||||
$arg =~ s/\b$addr\b/window$n/g if ( defined $n );
|
||||
}
|
||||
if ( $arg =~ /add_wch\((window\d+,)?0x[[:xdigit:]]+\)/i ) {
|
||||
$arg =~ s/(0x[[:xdigit:]]+)[)]/\&wch)/i;
|
||||
|
Loading…
Reference in New Issue
Block a user