Mercurial > gnulib
view tests/test-copy-file-1.sh @ 40212:8da9577294da
unistr/*, uniconv/*: Fix undefined behaviour.
Reported by Jeffrey Walton <noloader@gmail.com>.
* lib/unistr/u-cpy.h (FUNC): Don't invoke memcpy with a zero size.
* lib/unistr/u-cpy-alloc.h (FUNC): Likewise.
* lib/uniconv/u8-conv-from-enc.c (u8_conv_from_encoding): Likewise.
* lib/uniconv/u8-conv-to-enc.c (u8_conv_to_encoding): Likewise.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Sat, 09 Mar 2019 00:01:47 +0100 |
parents | b5d610935bea |
children |
line wrap: on
line source
#!/bin/sh # Test copy-file on the file system of /var/tmp, which usually is a local # file system. . "${srcdir=.}/init.sh"; path_prepend_ . if test -d /var/tmp; then TMPDIR=/var/tmp else TMPDIR=/tmp fi test -d $TMPDIR || Exit 77 export TMPDIR $BOURNE_SHELL "${srcdir}/test-copy-file.sh" ret1=$? NO_STDERR_OUTPUT=1 $BOURNE_SHELL "${srcdir}/test-copy-file.sh" ret2=$? case $ret1 in 77 ) Exit $ret2 ;; * ) Exit $ret1 ;; esac