X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2Fcommon.h;h=32b9ab3ac57b1825a9655fc36da898a6602cd19b;hb=84a55f12e5880196623d4193bf1d7f5141e6b0d5;hp=1a6ca8b3cc032515d42edcec9f43a9e94e75cfde;hpb=2947023d277cb0a787c73721d6190a75444cd65f;p=chaz%2Ftar diff --git a/src/common.h b/src/common.h index 1a6ca8b..32b9ab3 100644 --- a/src/common.h +++ b/src/common.h @@ -60,6 +60,8 @@ #define obstack_chunk_alloc xmalloc #define obstack_chunk_free free #include +#include +#include #include @@ -70,9 +72,6 @@ /* Information gleaned from the command line. */ -/* Name of this program. */ -GLOBAL const char *program_name; - /* Main command option. */ enum subcommand @@ -400,6 +399,7 @@ extern char *volume_label; extern char *continued_file_name; extern uintmax_t continued_file_size; extern uintmax_t continued_file_offset; +extern off_t records_written; size_t available_space_after (union block *pointer); off_t current_block_ordinal (void); @@ -453,7 +453,7 @@ void finish_header (struct tar_stat_info *st, union block *header, void simple_finish_header (union block *header); union block * write_extended (bool global, struct tar_stat_info *st, union block *old_header); -union block *start_private_header (const char *name, size_t size); +union block *start_private_header (const char *name, size_t size, time_t t); void write_eot (void); void check_links (void); void exclusion_tag_warning (const char *dirname, const char *tagname, @@ -718,7 +718,7 @@ void xheader_decode_global (struct xheader *xhdr); void xheader_store (char const *keyword, struct tar_stat_info *st, void const *data); void xheader_read (struct xheader *xhdr, union block *header, size_t size); -void xheader_write (char type, char *name, struct xheader *xhdr); +void xheader_write (char type, char *name, time_t t, struct xheader *xhdr); void xheader_write_global (struct xheader *xhdr); void xheader_finish (struct xheader *hdr); void xheader_destroy (struct xheader *hdr); @@ -827,3 +827,11 @@ extern int warning_option; } \ while (0) +/* Module unlink.c */ + +void queue_deferred_unlink (const char *name, bool is_dir); +void finish_deferred_unlinks (void); + +/* Module exit.c */ +extern void (*fatal_exit_hook) (void); +