1# Process this file with autom4te to create testsuite. -*- Autotest -*- 2 3# Test suite for GNU tar. 4# Copyright (C) 2006 Free Software Foundation, Inc. 5 6# This program is free software; you can redistribute it and/or modify 7# it under the terms of the GNU General Public License as published by 8# the Free Software Foundation; either version 2, or (at your option) 9# any later version. 10 11# This program is distributed in the hope that it will be useful, 12# but WITHOUT ANY WARRANTY; without even the implied warranty of 13# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14# GNU General Public License for more details. 15 16# You should have received a copy of the GNU General Public License 17# along with this program; if not, write to the Free Software 18# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 19# 02110-1301, USA. 20 21# Description: Rewritten incremental backup support (2006-05-08) 22# missed initialization of all struct directory members in make_directory, 23# which lead to random core dumps. 24# Reported by Sergey Myasnikov <tigra@sw.ru>. This testcase uses original 25# script provided by him. 26# References: <1148669592.5127.81.camel@tigra.sw.ru> 27# http://lists.gnu.org/archive/html/bug-tar/2006-05/msg00038.html 28 29AT_SETUP([proper icontents initialization]) 30AT_KEYWORDS([incremental incr04 icontents]) 31 32m4_define([NAME_PREFIX],[a/b/one_31_chars_long_file_name_]) 33 34AT_TAR_CHECK([ 35AT_TAR_MKHIER(a/b) 36awk 'BEGIN { 37 for (i=1;i<=142;i++) 38 printf("NAME_PREFIX[%03d]\n", i); 39 }' < /dev/null | genfile --files-from - 40 41echo "Initial dump" 42tar cvf a0.tar -g a.sna a 43mv a/b a/c 44echo "Incremental dump" 45tar cvf a1.tar -g a.sna a 46], 47[0], 48[Initial dump 49a/ 50a/b/ 51m4_for(I,1,142,1,[NAME_PREFIX[]m4_if(m4_len(I),1,00,m4_len(I),2,0)I 52])dnl 53Incremental dump 54a/ 55a/c/ 56], 57[tar: a/b: Directory is new 58tar: a/c: Directory has been renamed from `a/b' 59],[],[],[gnu, oldgnu, posix]) 60 61AT_CLEANUP 62 63# End of incr04.at 64