/[tar]/tar/src/common.h
ViewVC logotype

Diff of /tar/src/common.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.23 by eggert, Thu Nov 13 06:23:23 2003 UTC revision 1.24 by gray, Mon Nov 17 07:34:16 2003 UTC
# Line 309  struct name Line 309  struct name
309      char name[1];      char name[1];
310    };    };
311    
 /* Information about a sparse file.  */  
 struct sp_array  
   {  
     off_t offset;  
     size_t numbytes;  
   };  
 GLOBAL struct sp_array *sparsearray;  
   
 /* Number of elements in sparsearray.  */  
 GLOBAL int sp_array_size;  
   
312  /* Obnoxious test to see if dimwit is trying to dump the archive.  */  /* Obnoxious test to see if dimwit is trying to dump the archive.  */
313  GLOBAL dev_t ar_dev;  GLOBAL dev_t ar_dev;
314  GLOBAL ino_t ar_ino;  GLOBAL ino_t ar_ino;
# Line 366  void archive_read_error (void); Line 355  void archive_read_error (void);
355    
356  /* Module create.c.  */  /* Module create.c.  */
357    
358    enum dump_status
359      {
360        dump_status_ok,
361        dump_status_short,
362        dump_status_fail,
363        dump_status_not_implemented
364      };
365    
366    bool file_dumpable_p (struct tar_stat_info *stat);
367  void create_archive (void);  void create_archive (void);
368    void pad_archive (off_t size_left);
369  void dump_file (char *, int, dev_t);  void dump_file (char *, int, dev_t);
370  void finish_header (union block *, off_t);  union block *start_header (struct tar_stat_info *st);
371  void init_sparsearray (void);  void finish_header (struct tar_stat_info *, union block *, off_t);
372  void write_eot (void);  void write_eot (void);
373  void check_links (void);  void check_links (void);
374    
# Line 408  void verify_volume (void); Line 407  void verify_volume (void);
407    
408  extern bool we_are_root;  extern bool we_are_root;
409  void extr_init (void);  void extr_init (void);
 bool fill_in_sparse_array (void);  
410  void extract_archive (void);  void extract_archive (void);
411  void extract_finish (void);  void extract_finish (void);
412  void fatal_exit (void) __attribute__ ((noreturn));  void fatal_exit (void) __attribute__ ((noreturn));
# Line 478  uintmax_t uintmax_from_header (const cha Line 476  uintmax_t uintmax_from_header (const cha
476    
477  void list_archive (void);  void list_archive (void);
478  void print_for_mkdir (char *, int, mode_t);  void print_for_mkdir (char *, int, mode_t);
479  void print_header (off_t);  void print_header (struct tar_stat_info *, off_t);
480  void read_and (void (*) (void));  void read_and (void (*) (void));
481  enum read_header read_header (bool);  enum read_header read_header (bool);
482  void skip_file (off_t);  void skip_file (off_t);
# Line 518  void chmod_error_details (char const *, Line 516  void chmod_error_details (char const *,
516  void chown_error_details (char const *, uid_t, gid_t);  void chown_error_details (char const *, uid_t, gid_t);
517  void close_error (char const *);  void close_error (char const *);
518  void close_warn (char const *);  void close_warn (char const *);
519    void close_diag (char const *name);
520  void exec_fatal (char const *) __attribute__ ((noreturn));  void exec_fatal (char const *) __attribute__ ((noreturn));
521  void link_error (char const *, char const *);  void link_error (char const *, char const *);
522  void mkdir_error (char const *);  void mkdir_error (char const *);
# Line 526  void mknod_error (char const *); Line 525  void mknod_error (char const *);
525  void open_error (char const *);  void open_error (char const *);
526  void open_fatal (char const *) __attribute__ ((noreturn));  void open_fatal (char const *) __attribute__ ((noreturn));
527  void open_warn (char const *);  void open_warn (char const *);
528    void open_diag (char const *name);
529  void read_error (char const *);  void read_error (char const *);
530  void read_error_details (char const *, off_t, size_t);  void read_error_details (char const *, off_t, size_t);
531  void read_fatal (char const *) __attribute__ ((noreturn));  void read_fatal (char const *) __attribute__ ((noreturn));
532  void read_fatal_details (char const *, off_t, size_t);  void read_fatal_details (char const *, off_t, size_t);
533  void read_warn_details (char const *, off_t, size_t);  void read_warn_details (char const *, off_t, size_t);
534    void read_diag_details (char const *name, off_t offset, size_t size);
535  void readlink_error (char const *);  void readlink_error (char const *);
536  void readlink_warn (char const *);  void readlink_warn (char const *);
537    void readlink_diag (char const *name);
538  void savedir_error (char const *);  void savedir_error (char const *);
539  void savedir_warn (char const *);  void savedir_warn (char const *);
540    void savedir_diag (char const *name);
541  void seek_error (char const *);  void seek_error (char const *);
542  void seek_error_details (char const *, off_t);  void seek_error_details (char const *, off_t);
543  void seek_warn (char const *);  void seek_warn (char const *);
544  void seek_warn_details (char const *, off_t);  void seek_warn_details (char const *, off_t);
545    void seek_diag_details (char const *, off_t);
546  void stat_error (char const *);  void stat_error (char const *);
547  void stat_warn (char const *);  void stat_warn (char const *);
548    void stat_diag (char const *name);
549  void symlink_error (char const *, char const *);  void symlink_error (char const *, char const *);
550  void truncate_error (char const *);  void truncate_error (char const *);
551  void truncate_warn (char const *);  void truncate_warn (char const *);
# Line 600  bool contains_dot_dot (char const *); Line 605  bool contains_dot_dot (char const *);
605    
606  int confirm (const char *, const char *);  int confirm (const char *, const char *);
607  void request_stdin (const char *);  void request_stdin (const char *);
608  void destroy_stat (struct tar_stat_info *);  
609    void tar_stat_init (struct tar_stat_info *st);
610    void tar_stat_destroy (struct tar_stat_info *st);
611    
612  /* Module update.c.  */  /* Module update.c.  */
613    
# Line 635  bool sys_get_archive_stat (void); Line 642  bool sys_get_archive_stat (void);
642    
643  /* Module compare.c */  /* Module compare.c */
644  void report_difference (const char *message, ...);  void report_difference (const char *message, ...);
645    
646    /* Module sparse.c */
647    bool sparse_file_p (struct tar_stat_info *stat);
648    enum dump_status sparse_dump_file (int fd, struct tar_stat_info *stat);
649    enum dump_status sparse_extract_file (int fd, struct tar_stat_info *stat, off_t *size);

Legend:
Removed from v.1.23  
changed lines
  Added in v.1.24

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26