1 # Process this file with autom4te to create testsuite. -*- Autotest -*-
3 # Test suite for GNU tar.
4 # Copyright (C) 2011 Free Software Foundation, Inc.
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 3, or (at your option)
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.
16 # You should have received a copy of the GNU General Public License
17 # along with this program. If not, see <http://www.gnu.org/licenses/>.
19 # Description: Check the functionality of the --keep-old-files option.
20 # It should report an error and cause tar to exit with status 2.
22 # There was a regression in versions 1.23 to 1.26 inclusive, where
23 # this option silently skipped such files.
24 # Reported by: Doug McLaren <dougmc@frenzied.us>,
25 # Gary Partis <gary@partis.co.uk>,
26 # Jim Meyering <jim@meyering.net>
28 # References: <20111117045433.GA8245@algol.frenzied.us>,
29 # <4F3D824717847C4487F77228F83329A3514CBB@server.Partis.local>,
30 # <87wrar6zzz.fsf@rho.meyering.net>
32 AT_SETUP([keep-old-files])
33 AT_KEYWORDS([extract extrac18 old-files keep-old-files])
46 tar -x -k -f ../archive
55 [tar: ./a: Cannot open: File exists
56 tar: Exiting with failure status due to previous errors