Process Rock-Ridge time fields. Not tested or shown yet.
Break out Rock Ridge fields of our ISO9660 stat.
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
$Id: cd-info.c,v 1.118 2005/02/21 02:02:12 rocky Exp $
|
||||
$Id: cd-info.c,v 1.119 2005/02/21 09:00:53 rocky Exp $
|
||||
|
||||
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
|
||||
Copyright (C) 1996, 1997, 1998 Gerd Knorr <kraxel@bytesex.org>
|
||||
@@ -600,7 +600,7 @@ print_iso9660_recurse (CdIo_t *p_cdio, const char pathname[],
|
||||
char _fullname[4096] = { 0, };
|
||||
char translated_name[MAX_ISONAME+1];
|
||||
|
||||
if (yep != p_statbuf->b3_rock || 1 == opts.no_rock_ridge) {
|
||||
if (yep != p_statbuf->rr.b3_rock || 1 == opts.no_rock_ridge) {
|
||||
iso9660_name_translate_ext(psz_iso_name, translated_name,
|
||||
i_joliet_level);
|
||||
}
|
||||
@@ -618,9 +618,9 @@ print_iso9660_recurse (CdIo_t *p_cdio, const char pathname[],
|
||||
|
||||
print_fs_attrs(p_statbuf, 0 == opts.no_rock_ridge, fs & CDIO_FS_ANAL_XA,
|
||||
psz_iso_name, translated_name);
|
||||
if (p_statbuf->i_symlink) {
|
||||
free(p_statbuf->psz_symlink);
|
||||
p_statbuf->i_symlink = 0;
|
||||
if (p_statbuf->rr.i_symlink) {
|
||||
free(p_statbuf->rr.psz_symlink);
|
||||
p_statbuf->rr.i_symlink = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
$Id: iso-info.c,v 1.27 2005/02/21 02:02:12 rocky Exp $
|
||||
$Id: iso-info.c,v 1.28 2005/02/21 09:00:53 rocky Exp $
|
||||
|
||||
Copyright (C) 2004, 2005 Rocky Bernstein <rocky@panix.com>
|
||||
|
||||
@@ -203,7 +203,7 @@ print_iso9660_recurse (iso9660_t *p_iso, const char pathname[])
|
||||
char _fullname[4096] = { 0, };
|
||||
char translated_name[MAX_ISONAME+1];
|
||||
|
||||
if (yep != p_statbuf->b3_rock || 1 == opts.no_rock_ridge) {
|
||||
if (yep != p_statbuf->rr.b3_rock || 1 == opts.no_rock_ridge) {
|
||||
iso9660_name_translate_ext(psz_iso_name, translated_name,
|
||||
i_joliet_level);
|
||||
snprintf (_fullname, sizeof (_fullname), "%s%s", pathname,
|
||||
@@ -228,10 +228,11 @@ print_iso9660_recurse (iso9660_t *p_iso, const char pathname[])
|
||||
} else
|
||||
if ( strcmp (psz_iso_name, ".") && strcmp (psz_iso_name, ".."))
|
||||
printf("%9u %s%s\n", p_statbuf->size, pathname,
|
||||
yep == p_statbuf->b3_rock ? psz_iso_name : translated_name);
|
||||
if (p_statbuf->i_symlink) {
|
||||
free(p_statbuf->psz_symlink);
|
||||
p_statbuf->i_symlink = 0;
|
||||
yep == p_statbuf->rr.b3_rock
|
||||
? psz_iso_name : translated_name);
|
||||
if (p_statbuf->rr.i_symlink) {
|
||||
free(p_statbuf->rr.psz_symlink);
|
||||
p_statbuf->rr.i_symlink = 0;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
20
src/util.c
20
src/util.c
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
$Id: util.c,v 1.41 2005/02/21 02:02:12 rocky Exp $
|
||||
$Id: util.c,v 1.42 2005/02/21 09:00:53 rocky Exp $
|
||||
|
||||
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
|
||||
|
||||
@@ -463,12 +463,12 @@ print_fs_attrs(iso9660_stat_t *p_statbuf, bool b_rock, bool b_xa,
|
||||
{
|
||||
char date_str[30];
|
||||
|
||||
if (yep == p_statbuf->b3_rock && b_rock) {
|
||||
if (yep == p_statbuf->rr.b3_rock && b_rock) {
|
||||
report (stdout, " %s %d %d %d [LSN %6lu] %9u",
|
||||
iso9660_get_rock_attr_str (p_statbuf->st_mode),
|
||||
p_statbuf->st_nlinks,
|
||||
p_statbuf->st_uid,
|
||||
p_statbuf->st_gid,
|
||||
iso9660_get_rock_attr_str (p_statbuf->rr.st_mode),
|
||||
p_statbuf->rr.st_nlinks,
|
||||
p_statbuf->rr.st_uid,
|
||||
p_statbuf->rr.st_gid,
|
||||
(long unsigned int) p_statbuf->lsn,
|
||||
(unsigned int) p_statbuf->size);
|
||||
|
||||
@@ -494,14 +494,14 @@ print_fs_attrs(iso9660_stat_t *p_statbuf, bool b_rock, bool b_xa,
|
||||
}
|
||||
strftime(date_str, sizeof(date_str), "%b %d %Y %H:%M ", &p_statbuf->tm);
|
||||
report (stdout," %s %s", date_str,
|
||||
yep == p_statbuf->b3_rock && b_rock
|
||||
yep == p_statbuf->rr.b3_rock && b_rock
|
||||
? psz_name_untranslated : psz_name_translated);
|
||||
|
||||
if (yep == p_statbuf->b3_rock && b_rock && S_ISLNK(p_statbuf->st_mode)) {
|
||||
report(stdout, " -> %s", p_statbuf->psz_symlink);
|
||||
if (yep == p_statbuf->rr.b3_rock && b_rock
|
||||
&& S_ISLNK(p_statbuf->rr.st_mode)) {
|
||||
report(stdout, " -> %s", p_statbuf->rr.psz_symlink);
|
||||
}
|
||||
|
||||
report(stdout, "\n");
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
$Id: util.h,v 1.11 2005/02/20 10:21:01 rocky Exp $
|
||||
$Id: util.h,v 1.12 2005/02/21 09:00:53 rocky Exp $
|
||||
|
||||
Copyright (C) 2003, 2004, 2005 Rocky Bernstein <rocky@panix.com>
|
||||
|
||||
@@ -134,7 +134,7 @@ void report (FILE *stream, const char *psz_format, ...);
|
||||
|
||||
/* Prints "ls"-like file attributes */
|
||||
void print_fs_attrs(iso9660_stat_t *p_statbuf, bool b_rock, bool b_xa,
|
||||
const char *psz_name_untranslated,
|
||||
const char *psz_name_untranslated,
|
||||
const char *psz_name_translated);
|
||||
|
||||
#endif /* UTIL_H */
|
||||
|
||||
Reference in New Issue
Block a user