/* List a tar archive.
- Copyright (C) 1988, 1992 Free Software Foundation
+ Copyright (C) 1988, 1992, 1993 Free Software Foundation
This file is part of GNU Tar.
long from_oct (); /* Decode octal number */
void demode (); /* Print file mode */
+void restore_saved_dir_info ();
+PTR ck_malloc ();
union record *head; /* Points to current archive header */
struct stat hstat; /* Stat struct corresponding */
: head->header.arch_name);
if (current_file_name)
free (current_file_name);
- current_file_name = malloc (strlen (name) + 1);
+ current_file_name = ck_malloc (strlen (name) + 1);
strcpy (current_file_name, name);
name = (next_long_link
: head->header.arch_linkname);
if (current_link_name)
free (current_link_name);
- current_link_name = malloc (strlen (name) + 1);
+ current_link_name = ck_malloc (strlen (name) + 1);
strcpy (current_link_name, name);
next_long_link = next_long_name = 0;
int wantug;
{
long from_oct ();
- char **longp;
- char *bp, *data;
- int size, written;
st->st_mode = from_oct (8, header->header.mode);
+ st->st_mode &= 07777;
st->st_mtime = from_oct (1 + 12, header->header.mtime);
if (f_gnudump)
{
int pad;
char *name;
extern long baserec;
- static char *longname;
- static char *longlink;
- int bumplongs;
if (f_sayblock)
fprintf (msg_file, "rec %10d: ", baserec + (ar_record - ar_block));