Ryan Schmidt [Mon, 3 Dec 2018 18:10:41 +0000 (12:10 -0600)]
perl-module: Use unquoted perl config ld value
Fixes build failure when the perl config ld value contains multiple
words, such as on PowerPC Mac OS X where it may be a value like
'env MACOSX_DEPLOYMENT_TARGET=10.3 /usr/bin/gcc-4.2'.
Ben Pfaff [Thu, 28 Feb 2019 04:11:06 +0000 (20:11 -0800)]
sys-file-writer: Remove assertions based on file position.
These assertions can fail if the underlying file is not a regular file,
e.g. if it is a device such as /dev/null.
CVE-2019-9211.
See also https://bugzilla.redhat.com/show_bug.cgi?id=1683499.
See also https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2019-9211.
See also https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=923417.
Ben Pfaff [Sat, 23 Feb 2019 01:16:40 +0000 (17:16 -0800)]
pspp-dump-sav; Fix write past end of buffer in corner case.
If count == 0 and size > 0, then n_bytes is 0, buffer is a 1-byte
allocation, and the assignment to buffer[size] would write to buffer[1]
(or past it), which is past the end of the allocation.
Ben Pfaff [Sat, 12 Jan 2019 20:14:36 +0000 (12:14 -0800)]
encrypted-file: Extend magic numbers in try_password().
The three-byte magic numbers would match 1 in about every 16 million
guessed passwords, which is too frequent for exhaustive testing. The new
7- and 10-byte magic numbers should not have the same problem.
Ben Pfaff [Sun, 13 Jan 2019 00:41:25 +0000 (16:41 -0800)]
str: Fix bugs in ds_put_c_vformat().
This code used c_vasnprintf() as if it had the same interface as
vsnprintf(), but it's quite different. It is necessary to make note of its
return value and possibly free it. The code previously here didn't do
that, which led to memory leaks and possibly worse problems. (Fortunately
this function isn't used much.)
Ben Pfaff [Wed, 2 Jan 2019 22:46:11 +0000 (14:46 -0800)]
matrix-data: Only use as many bytes as necessary to initialize string.
Using strncpy() of a 9-character string to initialize an 8-byte field is
odd and seems likely to have been a mistake, although a harmless one.
This makes the situation seem less odd.
Ben Pfaff [Wed, 2 Jan 2019 22:22:24 +0000 (14:22 -0800)]
pivot-table: Fix type mismatch in equal_indexes().
This function was being called with an 'unsigned int *' but it took it
as a 'size_t *', which worked fine on 32-bit systems but caused an
enormous number of tests to fail on 64-bit systems.
Thanks to Alan Mead and John Darrington for assistance.
Ben Pfaff [Wed, 2 Jan 2019 17:20:51 +0000 (09:20 -0800)]
configure: Entirely avoid broken Texinfo.
Texinfo 4.13 was still causing problems on SuSE despite the implemented
workarounds, so this commit removes the workaround in favor of just using
the distributed pspp.xml if makeinfo is broken.
Requested by opensuse.lietuviu.kalba <opensuse.lietuviu.kalba@gmail.com>.
Ben Pfaff [Tue, 1 Jan 2019 19:12:36 +0000 (11:12 -0800)]
psppire-output-view: Add a little extra space to GtkLayout.
It can be difficult to see the bottom and right sides of the GtkLayout
because of the scroll bars that, on newer versions of GTK+ 3, seem to
actually overlap part of the content. Add a little extra space around
the output items to make it clearer.
Ben Pfaff [Mon, 31 Dec 2018 21:16:02 +0000 (13:16 -0800)]
psppire-output-viewer: Make sure that initial items are rendered at show.
When output items were shown in the output window, the first item
was not shown until the user moused over it and thereby triggered the
on_style_updated callback. This fixes the problem.
Ben Pfaff [Thu, 27 Dec 2018 04:29:50 +0000 (20:29 -0800)]
tests: Tag all the tests that take more than about 1s as "slow".
This makes it possible to run a quicker set of tests, which still have
pretty good coverage, with something like this:
make -j10 check TESTSUITEFLAGS='-j10 -k !slow'
Ben Pfaff [Wed, 26 Dec 2018 00:16:41 +0000 (16:16 -0800)]
cairo: Fix word-wrapping of ".000" and similar.
The Unicode line-breaking algorithm (or perhaps Pango's implementation of
it) is willing to break after the period in ".000". This looks odd. This
commit works around the problem.
Ben Pfaff [Mon, 26 Nov 2018 01:01:39 +0000 (17:01 -0800)]
output: Add support for cell margins.
Until now, space between cells was implemented by adding some space on the
sides of rules. That worked fine before cells could have colored
backgrounds, but now it means that the backgrounds don't reach all the way
to the rules. Thus, this commit adds configurable margins to the cells
themselves.