case 'f':
if (st)
{
- base = base_name (st->orig_file_name);
+ base = last_component (st->orig_file_name);
len += strlen (base) - 2;
}
break;
static void
mtime_coder (struct tar_stat_info const *st, char const *keyword,
- struct xheader *xhdr, void const *data __attribute__ ((unused)))
+ struct xheader *xhdr, void const *data)
{
- code_time (st->mtime, keyword, xhdr);
+ const struct timespec mtime = data ? *(struct timespec *) data : st->mtime;
+ code_time (mtime, keyword, xhdr);
}
static void