History log of /freebsd-10.2-release/tools/regression/lib/libc/
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
285830 23-Jul-2015 gjb

- Copy stable/10@285827 to releng/10.2 in preparation for 10.2-RC1
builds.
- Update newvers.sh to reflect RC1.
- Update __FreeBSD_version to reflect 10.2.
- Update default pkg(8) configuration to use the quarterly branch.[1]

Discussed with: re, portmgr [1]
Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

285795 22-Jul-2015 brueffer

MFC: r285543

Add a missing break statement, which made the code default to IPv6.

PR: 201285
Submitted by: David Binderman
Approved by: re (gjb)


283927 02-Jun-2015 jhb

MFC 281887:
Reassign copyright statements on several files from Advanced
Computing Technologies LLC to Hudson River Trading LLC.


281742 19-Apr-2015 jilles

MFC r280830: wordexp(): Add testcase for non-default IFS in environment.

The non-default IFS is expected to be used.


277548 23-Jan-2015 ngie

MFC r277453:

r277453 (by ngie):

Garbage collect a prove test wrapper

Sponsored by: EMC / Isilon Storage Division


277446 20-Jan-2015 ngie

MFC r267004,r274592:

r267004 (by gahr):

- Use strlen instead of hardcoding a number
- Terminate a sentence with a period

Approved by: cognet

r274592 (by ngie):

Convert tools/regression/lib/libc/stdio/test-fmemopen into an ATF testcase and
rename as lib/libc/stdio/fmemopen2_test

Sponsored by: EMC / Isilon Storage Division


277441 20-Jan-2015 ngie

MFC r274075,r274581,r274582,r274595:

r274075 (by ngie):

Add reachover Makefiles for contrib/netbsd-tests/lib/libc; this adds approximately
500 new testcases

Various TODOs have been sprinkled around the Makefiles for items that even need
to be ported (missing features), testcases have issues with building/linking, or
issues at runtime.

A variant of this code has been tested extensively on amd64 and i386
10-STABLE/11-CURRENT for several months without issue. It builds on other
architectures, but the code will remain off until I have prove it works on
virtual hardware or real hardware on other architectures

In collaboration with: pho, Casey Peel <casey.peel@isilon.com>
Sponsored by: EMC / Isilon Storage Division

r274581 (by ngie):

Convert tools/regression/lib/libc/gen/test-arc4random into an ATF testcase and
rename as lib/libc/gen/arc4random_test

Sponsored by: EMC / Isilon Storage Division

r274582 (by ngie):

Remove test-arc4random from this Makefile so others can continue to use
this as-is for the time being

r274595 (by ngie):

Convert tools/regression/lib/libc/stdio/test-fpclassify into an ATF testcase and
Rename as lib/libc/stdio/fpclassify2_test

Sponsored by: EMC / Isilon Storage Division


277016 11-Jan-2015 ngie

MFC discussed with: jilles, -developers

MFC r266971:

- Return NULL and set errno to EINVAL if size is 0 (as required by POSIX).
Update the manpage to reflect this change.
- Always set the current position to the first null-byte when opening in append
mode. This makes the implementation compatible with glibc's. Update the test
suite.

Reported by: pho
Approved by: cognet


276486 31-Dec-2014 ngie

MFC r264400,r265836:

r264400:

NO_MAN= has been deprecated in favor of MAN= for some time, go ahead
and finish the job. ncurses is now the only Makefile in the tree that
uses it since it wasn't a simple mechanical change, and will be
addressed in a future commit.

r265836:

Remove last two NO_MAN= in the tree. In both of these cases, MAN= is
what is needed.


264457 14-Apr-2014 jmmv

MFC various fixes to the tools/regression/ tests.

- r262953 Fix m4 tests so that they run cleanly with prove.
- r262954 Fix printf tests so that they run cleanly with prove.
- r262959 Fix sed tests so that they run cleanly with prove.
- r262960 Fix yacc tests so that they run cleanly with prove.
- r262961 Fix pkill tests so that they run cleanly with prove.
- r262962 Fix ncal tests so that they run cleanly with prove.
- r263081 Fix lastcomm tests under amd64.
- r263082 Only run the make tests when make is fmake.
- r263083 Fix sa tests.
- r263084 Turn a test precondition into a skip in the mdconfig tests.
- r263085 Make the strerror tests work without libtap.
- r263087 Remove broken tests for eui64_line.
- r263221 Change etcupdate tests to return 1 on test failures.
- r263352 Make the priv test program exit with non-zero if any failures are detected.
- r263353 errx prepends the program name to the message; don't do it by hand.
- r263362 Include strings.h so that bpf_filter.c can be built in userland.


256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


255303 06-Sep-2013 jilles

libc/stdio: Allow fopen/freopen modes in any order (except initial r/w/a).

Austin Group issue #411 requires 'e' to be accepted before and after 'x',
and encourages accepting the characters in any order, except the initial
'r', 'w' or 'a'.

Given that glibc accepts the characters after r/w/a in any order and that
diagnosing this problem may be hard, change our libc to behave that way as
well.


255302 06-Sep-2013 jilles

libc/stdio: Run mkostemp test using prove.


255301 06-Sep-2013 jilles

libc/stdio: Provide proper TAP output for fmemopen/open_[w]memstream.

A *.t file should provide Test Anything Protocol output so that it can be
run using the Perl "prove" tool.


254231 11-Aug-2013 jilles

fnmatch(): Add test for r254091 (pattern with single backslash).

This test cannot be converted to an sh(1) test because the syntax would be
invalid.

PR: 181129
MFC after: 1 week


254151 09-Aug-2013 jilles

Add mkostemp() and mkostemps().

These are like mkstemp() and mkstemps() but allow passing open(2) flags like
O_CLOEXEC.


253581 23-Jul-2013 jilles

wordexp(): Fix syntax validation for backslashes in single-quotes.


253403 17-Jul-2013 kevlo

Add missing headers.


251867 17-Jun-2013 eadler

Restore "all rights reserved" (spelled correctly). This was actually part of the standard text of the license which I did not realize prior.

Approved by: bushman


251818 16-Jun-2013 eadler

Remove lines declaring "All rights reserved" or similar comments: they
are not true as the files are actually under the BSD-2 license

Approved by: bushman


251314 03-Jun-2013 ed

Add libiconv based versions of *c16*() and *c32*().

I initially thought wchar_t was locale independent, but this seems to be
only the case on Linux. This means that we cannot depend on the *wc*()
routines to implement *c16*() and *c32*(). Instead, use the Citrus
libiconv that is part of libc.

I'll see if there is anything I can do to make the existing functions
somewhat useful in case the system is built without libiconv in the
nearby future. If not, I'll simply remove the broken implementations.

Reviewed by: jilles, gabor


250989 25-May-2013 ed

Add missing #includes, to keep Clang silent.


250883 21-May-2013 ed

Add <uchar.h>.

The <uchar.h> header, part of C11, adds a small number of utility
functions for 16/32-bit "universal" characters, which may or may not be
UTF-16/32. As our wchar_t is already ISO 10646, simply add light-weight
wrappers around wcrtomb() and mbrtowc().

While there, also add (non-yet-standard) _l functions, similar to the
ones we already have for the other locale-dependent functions.

Reviewed by: theraven


250827 20-May-2013 jilles

popen(): Add 'e' mode character to set close-on-exec on the new fd.

If 'e' is used, the kernel must support the recently added pipe2() system
call.

The use of pipe2() with O_CLOEXEC also fixes race conditions between
concurrent popen() calls from different threads, even if the close-on-exec
flag on the fd of the returned FILE is later cleared (because popen() closes
all file descriptors from earlier popen() calls in the child process).
Therefore, this approach should be used in all cases when pipe2() can be
assumed present.

The old version of popen() rejects "re" and "we" but treats "r+e" like "r+".


250825 20-May-2013 jilles

Add a test program for popen().


248987 01-Apr-2013 jilles

wordexp(): Remove wrong IFS usage.

Words in shell script are separated by spaces or tabs independent of the
value of IFS. The value of IFS is only relevant for the result of
substitutions. Therefore, there should be a space between 'wordexp' and the
words to be expanded, not an IFS character.

Paranoia might dictate that the shell ignore IFS from the environment (even
though our sh currently uses it), so do not depend on it in the new test
case.


247411 27-Feb-2013 jhb

Add an implementation of open_memstream() and open_wmemstream(). These
routines provide write-only stdio FILE objects that store their data in a
dynamically allocated buffer. They are a string builder interface somewhat
akin to a completely dynamic sbuf.

Reviewed by: bde, jilles (earlier versions)
MFC after: 1 month


246206 01-Feb-2013 gahr

- Fix more style(9)-related issues (copyright header, spaces after function
names, unnecessary casts)
- Change type of boolean variable from char to bool

Suggested by: jhb, zont, jmallett
Reviewed by: cognet
Approved by: cognet


246148 31-Jan-2013 gahr

- Remove underscores from the internal structure name, as it doesn't collide
with the user's namespace.

- Correct size and position variables type from long to size_t.

- Do not set errno to ENOMEM on malloc failure, as malloc already does so.

- Implement the concept of "buffer data length", which mandates what SEEK_END
refers to and the allowed extent for a read.

- Use NULL as read-callback if the buffer is opened in write-only mode.
Conversely, use NULL as write-callback when opened in read-only mode.

- Implement the handling of the ``b'' character in the mode argument. A binary
buffer differs from a text buffer (default mode if ``b'' is omitted) in that
NULL bytes are never appended to writes and that the "buffer data length"
equals to the size of the buffer.

- Remove shall from the man page. Use indicative instead. Also, specify that
the ``b'' flag does not conform with POSIX but is supported by glibc.

- Update the regression test so that the ``b'' functionality and the "buffer
data length" concepts are tested.

- Minor style(9) corrections.

Suggested by: jilles
Reviewed by: cognet
Approved by: cognet


246120 30-Jan-2013 gahr

Add fmemopen(3), an interface to get a FILE * from a buffer in memory, along
with the respective regression test.
See http://pubs.opengroup.org/onlinepubs/9699919799/functions/fmemopen.html

Reviewed by: cognet
Approved by: cognet


244038 08-Dec-2012 jilles

libc: Add a missing header to a test program.

Usage of dup(), mkstemp() and unlink() needs <unistd.h>.


243346 20-Nov-2012 emaste

Non-void function should return a value.

Found by: clang


241844 22-Oct-2012 eadler

remove duplicate semicolons where possible.

Approved by: cperciva
MFC after: 1 week


239160 09-Aug-2012 jilles

nftw(): POSIX says directories causing loops should be silently skipped.

Formerly, loops caused nftw() to abort the traversal with ELOOP.


231984 21-Feb-2012 jilles

libc: Add some tests for fmtmsg().


230115 14-Jan-2012 das

Add .t files for tests, missed in prior checkins, so that prove(1) works
in this directory.


230114 14-Jan-2012 das

Update the tests for arm and other ports where long double is the same
as double, similar to r178141.


228975 30-Dec-2011 uqs

Spelling fixes for tools/

Add some $FreeBSD$ tags so svn will allow the commit.


227522 15-Nov-2011 das

A regression test to ensure that arc4random returns different sequences
in parent and child processes after a fork.


223907 10-Jul-2011 jilles

posix_spawn: If an error is detected in the child process, reap the zombie.

Formerly, in this case an error was returned but the pid was also returned
to the application, requiring the application to use unspecified behaviour
(the returned pid in error situations) to avoid zombies.

Now, reap the zombie and do not return the pid.

MFC after: 2 weeks


220376 05-Apr-2011 jilles

Allow strerror(0) and strerror_r(0, ...).

Of course, strerror_r() may still fail with ERANGE.

Although the POSIX specification said this could fail with EINVAL and
doing this likely indicates invalid use of errno, most other
implementations permitted it, various POSIX testsuites require it to
work (matching the older sys_errlist array) and apparently some
applications depend on it.

PR: standards/151316
MFC after: 1 week


207821 09-May-2010 jilles

Generate some tests for sh's case command from the fnmatch tests.

I'm committing the generated files because I don't like a build dependency
for the sh(1) tests, and they are small and will not change much.


206711 16-Apr-2010 jilles

fnmatch: Fix bad FNM_PERIOD disabling if an asterisk has been seen.

Example: fnmatch("a*b/*", "abbb/.x", FNM_PATHNAME | FNM_PERIOD)

PR: 116074
MFC after: 1 week


206710 16-Apr-2010 jilles

Add some tests for fnmatch(3).

MFC after: 1 week


204627 03-Mar-2010 joel

The NetBSD Foundation has granted permission to remove clause 3 and 4 from
their software.

Obtained from: NetBSD


198406 23-Oct-2009 jilles

wordexp(3): fix some bugs with signals and long outputs
* retry various system calls on EINTR
* retry the rest after a short read (common if there is more than about 1K
of output)
* block SIGCHLD like system(3) does (note that this does not and cannot
work fully in threaded programs, they will need to be careful with wait
functions)

PR: 90580
MFC after: 1 month


197753 04-Oct-2009 das

Regression tests for r197752 (handling of empty/NULL buffers).


190773 06-Apr-2009 das

Return -1 instead of 0 upon reaching EOF. This is somewhat ill-advised
because it means getdelim() returns -1 for both error and EOF, and
never returns 0. However, this is what the original GNU implementation
does, and POSIX inherited the bug.

Reported by: marcus@


189142 28-Feb-2009 das

Tests for getdelim().


189141 28-Feb-2009 das

Add a file containing tests for simple format specifiers.
Currently it only has tests for a few sign issues with integer
formats, including PR 131880.


189140 28-Feb-2009 das

Tests for wcscasecmp(), wcsnlen(), and stpncpy().


187963 31-Jan-2009 das

Test wprintf() in addition to printf().


182711 03-Sep-2008 das

Regression tests for bugs in gdtoa.


181155 02-Aug-2008 das

Regression tests for fmtcheck(3).

Obtained from: NetBSD


180103 29-Jun-2008 das

Add some regression tests for printf() with positional arguments.
The first test comes from OpenBSD, and the others are additions or
adaptations.

This is based on OpenBSD's
src/regress/lib/libc/sprintf/sprintf_test.c, v1.3.
I deliberately did not use v1.4 because it's bogus.


179919 21-Jun-2008 das

Regression test for a recently fixed strtod bug.


178141 12-Apr-2008 das

Updates for changes in the way printf() handles hex floating point
numbers.


174692 16-Dec-2007 das

Fix an amusing typo that has prevented this from compiling since 2004.


174495 09-Dec-2007 das

Remove some test instrumentation. (The Symbol.map changes broke it anyway.)


174228 03-Dec-2007 das

Make sure we set the locale to "C" when testing thousands' separator
support, rather than just "", which refers to the system default based
on the environment.


174205 03-Dec-2007 das

Tests for rounding, and for the leading 0's bug.


171016 24-Jun-2007 bushman

- Bugs in gethostbyXXX/getipnodebyXXX regression tests fixed.
Tests for getipnodebyXXX functions now cover most number of flags
combinations.

Approved by: re (kensmith), brooks (mentor)


169523 13-May-2007 rwatson

Add regression tests for ethers(3) functions, including new _r variants.
Four tests currently fail:

test_ether_line_bad_1() and test_ether_line_bad_2() due to bugs in
ether_line(3).

test_ether_ntohost() and test_ether_hostton() due to not being fully
implemented tests.


168754 15-Apr-2007 bushman

Committing regression tests for all implemented nsswitch databases.
Detailed description and instructions are in the README file.
This work had been basically done during GSoC 2006.

Approved by: brooks (mentor)


165754 03-Jan-2007 das

Remove the test that ensures that when the string "nan(...)" is converted
to floating-point, the result is a quiet NaN. The current implementation
may return a signaling NaN, and the vendor has no plans for changing this,
for reasons explained in the comment I added.


165748 03-Jan-2007 das

Fix cut-and-paste bugs in the regression tests.


156735 15-Mar-2006 ru

Style: NO_MAN doesn't need any value.


156391 07-Mar-2006 ume

NOMAN --> NO_MAN


145901 05-May-2005 ume

add simple test script.


145885 04-May-2005 ume

- add $FreeBSD$.
- enable -r option for regress target.


145860 04-May-2005 ume

- add $FreeBSD$.
- do service lookup.
- add options to use gethostbyname(3) or getipnodebyname(3) instead
of getaddrinfo(3).
- add option to do reverse lookup.


145858 04-May-2005 ume

This commit was generated by cvs2svn to compensate for changes in r145857,
which included commits to RCS files with non-trunk default branches.


142843 01-Mar-2005 das

- Split tests into three rough categories.
- Use fesetround() instead of fpsetround(), and add tests for
various rounding modes.
- Test that all NaNs generated are quiet.

Some of these tests won't pass until problems in vendor sources
(gdtoa and gcc) are fixed and new versions imported, but I
want to get these changes into the tree before I accidentally
blow them away again. :-(


142842 01-Mar-2005 das

- Split the printfloat test into 11 individually wrapped and packaged
tests. (Buy 10, get one free!) The separate categories were
already there; they just weren't labeled.
- Use fesetround() instead of fpsetround(), since the former is
standard and implemented on all supported architectures. Add
tests for each rounding mode.
- Add additional tests for subnormals.

Some of these tests won't pass until problems in vendor sources
(gdtoa and gcc) are fixed and new versions imported, but I
want to get these changes into the tree before I accidentally
blow them away.


141750 12-Feb-2005 ru

Add to CFLAGS.


141097 01-Feb-2005 nik

Add to CFLAGS, rather than overriding it. Use LDFLAGS for the -L option,
and LDLIBS to specify -ltap.

Submitted by: ru


141092 01-Feb-2005 nik

Link against libtap (ports/devel/libtap). Replace the calls to assert()
with calls to libtap::ok1(), and make sure the correct number of tests is
planned for, and that the exit code is correct.


137960 21-Nov-2004 tjr

Remove regression tests for the obsolete rune interface.


137587 11-Nov-2004 nik

Switch over to a different, more flexible test output protocol that's
understood by Perl's Test::Harness module and prove(1) commands.

Update README to describe the new protocol. The work's broken down into
two main sets of changes.

First, update the existing test programs (shell scripts and C programs)
to produce output in the ok/not ok format, and to, where possible, also
produce a header describing the number of tests that are expected to be
run.

Second, provide the .t files that actually run the tests. In some cases
these are copies of, or very similar too, scripts that already existed.
I've kept the old scripts around so that it's possible to verify that
behaviour under this new system (in terms of whether or not a test fails)
is identical to the behaviour under the old system.

Add a TODO file.


136497 13-Oct-2004 keramida

Add a regression test for floating-point output in the Greek locale.
See revision 1.3 of src/share/numericdef/el_GR.ISO8859-7.src

Reviewed by: das (a while ago)


132499 21-Jul-2004 tjr

Add test programs for mbsnrtowcs() and wcsnrtombs().


132392 19-Jul-2004 tjr

Add a skeleton makefile that runs the tests out of libc/regex/grot.


132391 19-Jul-2004 tjr

Oops, test error behaviour of wctrans(), not wctype().


131099 25-Jun-2004 sobomax

Add qsort, mergesort and heapsort regression tests.


129782 27-May-2004 brooks

Fix stupid patch(1) tricks. Apparently patch thinks all files match the
empty file so if you accidently apply a patch created with diff -N
twice, you get files with duplicate contents.

Reported by: Antoine Brodin <antoine.brodin at laposte.net>


129759 26-May-2004 brooks

Add support for an /etc/eui64 file modeled on /etc/ethers. The API is
modeled on ethers(3) except that all functions are thread-safe.

Reviewed by: simokawa


129115 11-May-2004 tjr

Test accumulation of partial multibyte characters in conversion
state objects.


128005 07-Apr-2004 tjr

Reset internal conversion state after triggering conversion errors;
the state is undefined according to the standards, and our undefined
behaviour has changed.


124708 19-Jan-2004 das

Add regression tests for printf's %a/%A formats.

While here, disable some of the long double tests on i386, since
FreeBSD/i386 is the only port that doesn't evaluate long doubles in
their full precision (due to constant folding bugs in gcc).


124707 19-Jan-2004 das

Add regression tests for some of the bugs recently discovered in the
vendor's strtod() implementation.

While here, disable some of the long double tests on i386, since
FreeBSD/i386 is the only port that doesn't evaluate long doubles in
their full precision (due to constant folding bugs in gcc).


124650 18-Jan-2004 das

Work around a recently-introduced gcc bug. The compiler no longer
accepts certain floating point constant representations that are
legal in C99.


121732 30-Oct-2003 tjr

Add regression tests for sgetrune() and sputrune().


116969 28-Jun-2003 das

Add regression tests for floating point parsing in scanf(3).


115894 06-Jun-2003 tjr

Regression tests for wctype(), iswctype(), wctrans(), towctrans().


113724 19-Apr-2003 das

Add a dozen new tests with the general theme of getting trailing
zeroes right.


113469 14-Apr-2003 das

Add a test case for printf("%5.0f", 0.001).


113192 07-Apr-2003 das

Additional regression tests for grouping, parsing of '.*', and printing
of %f formats where the number of significant digits is < expt.


113162 06-Apr-2003 tjr

Test for bug in revision 1.54 of vfprintf.c.


113147 05-Apr-2003 das

Regression tests for printf()'s floating point formats.
Tests for correct printing of subnormals are lacking.


112698 27-Mar-2003 das

Write negative zero as '-0.0'. Otherwise, it is parsed as an integer
before being cast to a floating point type, and the sign is lost.


110569 08-Feb-2003 mike

Add more tests. Specifically, infinity cast from other types should
always be classified as infinity.


110405 05-Feb-2003 mike

Add regression test for soon-to-be-committed fpclassify().


108639 04-Jan-2003 tjr

Add a regression test for wordexp() and wordfree().


108088 19-Dec-2002 tjr

Add a test program for perror() that demonstrates two bugs in the
current implementation.


108069 19-Dec-2002 tjr

Test that if the buffer argument (`s') to wcrtomb() is NULL then
the value of the supplied wide character is ignored and L'\0' is used
instead. Remove incorrect comments about "internal buffer" since wcrtomb()
does not have one (wctomb() does).


108045 18-Dec-2002 mike

Add regression test for strerror()/strerror_r().

Based on: src/lib/libc/string/strerror.c (rev 1.8)


106727 10-Nov-2002 tjr

Add test cases for btowc() and wctob() in multibyte locales.


106726 10-Nov-2002 tjr

Test for the zero-length buffer bug corrected in mbrtowc.c revision 1.3.


106686 09-Nov-2002 tjr

Add regression tests for mblen(), mbtowc(), wctomb(), mbstowcs() and
wcstombs(). These tests have already found two libc bugs.


106495 06-Nov-2002 tjr

Add missing #includes of <stdio.h>. Correct a few typos in comments.


106080 28-Oct-2002 tjr

Simplify by using inference rules properly.


105980 26-Oct-2002 tjr

Add tests for btowc(), mbrlen(), mbsrtowcs() and wcsrtombs().


105973 26-Oct-2002 tjr

Add regression tests for mbrtowc(3) and wcrtomb(3).