mirror of
https://github.com/MidnightCommander/mc
synced 2025-04-07 07:33:16 +03:00
Following prototypes of functions was changed in VFS-module API:
* archive_check * archive_same * open_archive Signed-off-by: Slava Zanko <slavazanko@gmail.com>
This commit is contained in:
parent
e9ed6a41cf
commit
e6ec447585
@ -39,34 +39,30 @@ struct vfs_s_subclass test_subclass1, test_subclass2, test_subclass3;
|
|||||||
struct vfs_class vfs_test_ops1, vfs_test_ops2, vfs_test_ops3;
|
struct vfs_class vfs_test_ops1, vfs_test_ops2, vfs_test_ops3;
|
||||||
|
|
||||||
static int
|
static int
|
||||||
test1_mock_open_archive(struct vfs_class *me, struct vfs_s_super *super,
|
test1_mock_open_archive(struct vfs_s_super *super, const vfs_path_t *vpath, const vfs_path_element_t *vpath_element)
|
||||||
const vfs_path_t *vpath, char *op)
|
|
||||||
{
|
{
|
||||||
struct vfs_s_inode *root;
|
struct vfs_s_inode *root;
|
||||||
char *spath = vfs_path_to_str (vpath);
|
char *spath = vfs_path_to_str (vpath);
|
||||||
|
|
||||||
(void) op;
|
|
||||||
|
|
||||||
fail_unless(strcmp("/" ETALON_VFS_NAME ARCH_NAME, spath) == 0,
|
fail_unless(strcmp("/" ETALON_VFS_NAME ARCH_NAME, spath) == 0,
|
||||||
"etalon(%s) doesn't equal to actual(%s)", "/" ETALON_VFS_NAME ARCH_NAME, spath);
|
"etalon(%s) doesn't equal to actual(%s)", "/" ETALON_VFS_NAME ARCH_NAME, spath);
|
||||||
|
|
||||||
super->name = g_strdup (spath);
|
super->name = g_strdup (spath);
|
||||||
super->data = g_new (char *, 1);
|
super->data = g_new (char *, 1);
|
||||||
root = vfs_s_new_inode (me, super, NULL);
|
root = vfs_s_new_inode (vpath_element->class, super, NULL);
|
||||||
super->root = root;
|
super->root = root;
|
||||||
g_free(spath);
|
g_free(spath);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static int
|
static int
|
||||||
test1_mock_archive_same (struct vfs_class *me, struct vfs_s_super *super,
|
test1_mock_archive_same (const vfs_path_element_t *vpath_element, struct vfs_s_super *super,
|
||||||
const vfs_path_t *vpath, char *op, void *cookie)
|
const vfs_path_t *vpath, void *cookie)
|
||||||
{
|
{
|
||||||
vfs_path_element_t *path_element = vfs_path_get_by_index(vpath, -1);
|
vfs_path_element_t *path_element = vfs_path_get_by_index(vpath, -1);
|
||||||
|
|
||||||
(void) me;
|
(void) vpath_element;
|
||||||
(void) super;
|
(void) super;
|
||||||
(void) op;
|
|
||||||
(void) cookie;
|
(void) cookie;
|
||||||
|
|
||||||
if (strcmp(ARCH_NAME, path_element->path) != 0)
|
if (strcmp(ARCH_NAME, path_element->path) != 0)
|
||||||
|
@ -1069,8 +1069,7 @@ vfs_s_get_path_mangle (const vfs_path_t * vpath, struct vfs_s_super **archive, i
|
|||||||
|
|
||||||
if (subclass->archive_check != NULL)
|
if (subclass->archive_check != NULL)
|
||||||
{
|
{
|
||||||
cookie =
|
cookie = subclass->archive_check (vpath_archive);
|
||||||
subclass->archive_check (path_element->class, vpath_archive, path_element->raw_url_str);
|
|
||||||
if (cookie == NULL)
|
if (cookie == NULL)
|
||||||
{
|
{
|
||||||
vfs_path_free (vpath_archive);
|
vfs_path_free (vpath_archive);
|
||||||
@ -1085,8 +1084,7 @@ vfs_s_get_path_mangle (const vfs_path_t * vpath, struct vfs_s_super **archive, i
|
|||||||
super = (struct vfs_s_super *) iter->data;
|
super = (struct vfs_s_super *) iter->data;
|
||||||
|
|
||||||
/* 0 == other, 1 == same, return it, 2 == other but stop scanning */
|
/* 0 == other, 1 == same, return it, 2 == other but stop scanning */
|
||||||
i = subclass->archive_same (path_element->class, super, vpath_archive,
|
i = subclass->archive_same (path_element, super, vpath_archive, cookie);
|
||||||
path_element->raw_url_str, cookie);
|
|
||||||
if (i != 0)
|
if (i != 0)
|
||||||
{
|
{
|
||||||
if (i == 1)
|
if (i == 1)
|
||||||
@ -1104,9 +1102,7 @@ vfs_s_get_path_mangle (const vfs_path_t * vpath, struct vfs_s_super **archive, i
|
|||||||
|
|
||||||
super = vfs_s_new_super (path_element->class);
|
super = vfs_s_new_super (path_element->class);
|
||||||
if (subclass->open_archive != NULL)
|
if (subclass->open_archive != NULL)
|
||||||
result =
|
result = subclass->open_archive (super, vpath_archive, path_element);
|
||||||
subclass->open_archive (path_element->class, super, vpath_archive,
|
|
||||||
path_element->raw_url_str);
|
|
||||||
if (result == -1)
|
if (result == -1)
|
||||||
{
|
{
|
||||||
vfs_s_free_super (path_element->class, super);
|
vfs_s_free_super (path_element->class, super);
|
||||||
|
@ -124,11 +124,11 @@ struct vfs_s_subclass
|
|||||||
void (*free_inode) (struct vfs_class * me, struct vfs_s_inode * ino); /* optional */
|
void (*free_inode) (struct vfs_class * me, struct vfs_s_inode * ino); /* optional */
|
||||||
int (*init_entry) (struct vfs_class * me, struct vfs_s_entry * entry); /* optional */
|
int (*init_entry) (struct vfs_class * me, struct vfs_s_entry * entry); /* optional */
|
||||||
|
|
||||||
void *(*archive_check) (struct vfs_class * me, const vfs_path_t * vpath, char *op); /* optional */
|
void *(*archive_check) (const vfs_path_t * vpath); /* optional */
|
||||||
int (*archive_same) (struct vfs_class * me, struct vfs_s_super * psup,
|
int (*archive_same) (const vfs_path_element_t * vpath_element, struct vfs_s_super * psup,
|
||||||
const vfs_path_t * vpath, char *op, void *cookie);
|
const vfs_path_t * vpath, void *cookie);
|
||||||
int (*open_archive) (struct vfs_class * me, struct vfs_s_super * psup,
|
int (*open_archive) (struct vfs_s_super * psup,
|
||||||
const vfs_path_t * vpath, char *op);
|
const vfs_path_t * vpath, const vfs_path_element_t * vpath_element);
|
||||||
void (*free_archive) (struct vfs_class * me, struct vfs_s_super * psup);
|
void (*free_archive) (struct vfs_class * me, struct vfs_s_super * psup);
|
||||||
|
|
||||||
int (*fh_open) (struct vfs_class * me, vfs_file_handler_t * fh, int flags, mode_t mode);
|
int (*fh_open) (struct vfs_class * me, vfs_file_handler_t * fh, int flags, mode_t mode);
|
||||||
|
@ -714,15 +714,15 @@ cpio_read_crc_head (struct vfs_class *me, struct vfs_s_super *super)
|
|||||||
/** Need to CPIO_SEEK_CUR to skip the file at the end of add entry!!!! */
|
/** Need to CPIO_SEEK_CUR to skip the file at the end of add entry!!!! */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
cpio_open_archive (struct vfs_class *me, struct vfs_s_super *super, const vfs_path_t * vpath,
|
cpio_open_archive (struct vfs_s_super *super, const vfs_path_t * vpath,
|
||||||
char *op)
|
const vfs_path_element_t * vpath_element)
|
||||||
{
|
{
|
||||||
int status = STATUS_START;
|
int status = STATUS_START;
|
||||||
char *archive_name = vfs_path_to_str (vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
|
|
||||||
(void) op;
|
(void) vpath_element;
|
||||||
|
|
||||||
if (cpio_open_cpio_file (me, super, archive_name) == -1)
|
if (cpio_open_cpio_file (vpath_element->class, super, archive_name) == -1)
|
||||||
{
|
{
|
||||||
g_free (archive_name);
|
g_free (archive_name);
|
||||||
return -1;
|
return -1;
|
||||||
@ -730,7 +730,7 @@ cpio_open_archive (struct vfs_class *me, struct vfs_s_super *super, const vfs_pa
|
|||||||
|
|
||||||
while (TRUE)
|
while (TRUE)
|
||||||
{
|
{
|
||||||
status = cpio_read_head (me, super);
|
status = cpio_read_head (vpath_element->class, super);
|
||||||
|
|
||||||
switch (status)
|
switch (status)
|
||||||
{
|
{
|
||||||
@ -753,15 +753,12 @@ cpio_open_archive (struct vfs_class *me, struct vfs_s_super *super, const vfs_pa
|
|||||||
/** Remaining functions are exactly same as for tarfs (and were in fact just copied) */
|
/** Remaining functions are exactly same as for tarfs (and were in fact just copied) */
|
||||||
|
|
||||||
static void *
|
static void *
|
||||||
cpio_super_check (struct vfs_class *me, const vfs_path_t * vpath, char *op)
|
cpio_super_check (const vfs_path_t * vpath)
|
||||||
{
|
{
|
||||||
static struct stat sb;
|
static struct stat sb;
|
||||||
char *archive_name = vfs_path_to_str (vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
int stat_result;
|
int stat_result;
|
||||||
|
|
||||||
(void) me;
|
|
||||||
(void) op;
|
|
||||||
|
|
||||||
stat_result = mc_stat (archive_name, &sb);
|
stat_result = mc_stat (archive_name, &sb);
|
||||||
g_free (archive_name);
|
g_free (archive_name);
|
||||||
return (stat_result == 0 ? &sb : NULL);
|
return (stat_result == 0 ? &sb : NULL);
|
||||||
@ -770,14 +767,13 @@ cpio_super_check (struct vfs_class *me, const vfs_path_t * vpath, char *op)
|
|||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
cpio_super_same (struct vfs_class *me, struct vfs_s_super *parc,
|
cpio_super_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *parc,
|
||||||
const vfs_path_t * vpath, char *op, void *cookie)
|
const vfs_path_t * vpath, void *cookie)
|
||||||
{
|
{
|
||||||
struct stat *archive_stat = cookie; /* stat of main archive */
|
struct stat *archive_stat = cookie; /* stat of main archive */
|
||||||
char *archive_name = vfs_path_to_str (vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
|
|
||||||
(void) me;
|
(void) vpath_element;
|
||||||
(void) op;
|
|
||||||
|
|
||||||
if (strcmp (parc->name, archive_name))
|
if (strcmp (parc->name, archive_name))
|
||||||
{
|
{
|
||||||
|
@ -581,15 +581,17 @@ fish_open_archive_int (struct vfs_class *me, struct vfs_s_super *super)
|
|||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
fish_open_archive (struct vfs_class *me, struct vfs_s_super *super,
|
fish_open_archive (struct vfs_s_super *super,
|
||||||
const vfs_path_t * vpath, char *op)
|
const vfs_path_t * vpath, const vfs_path_element_t * vpath_element)
|
||||||
{
|
{
|
||||||
(void) vpath;
|
(void) vpath;
|
||||||
|
|
||||||
super->data = g_new0 (fish_super_data_t, 1);
|
super->data = g_new0 (fish_super_data_t, 1);
|
||||||
super->path_element = vfs_url_split (strchr (op, ':') + 1, 0, URL_NOSLASH | URL_USE_ANONYMOUS);
|
super->path_element =
|
||||||
|
vfs_url_split (strchr (vpath_element->raw_url_str, ':') + 1, 0,
|
||||||
|
URL_NOSLASH | URL_USE_ANONYMOUS);
|
||||||
|
|
||||||
if (strncmp (op, "rsh:", 4) == 0)
|
if (strncmp (vpath_element->raw_url_str, "rsh:", 4) == 0)
|
||||||
super->path_element->port = FISH_FLAG_RSH;
|
super->path_element->port = FISH_FLAG_RSH;
|
||||||
|
|
||||||
SUP->scr_ls =
|
SUP->scr_ls =
|
||||||
@ -631,23 +633,24 @@ fish_open_archive (struct vfs_class *me, struct vfs_s_super *super,
|
|||||||
fish_load_script_from_file (super->path_element->host, FISH_INFO_FILE,
|
fish_load_script_from_file (super->path_element->host, FISH_INFO_FILE,
|
||||||
FISH_INFO_DEF_CONTENT);
|
FISH_INFO_DEF_CONTENT);
|
||||||
|
|
||||||
return fish_open_archive_int (me, super);
|
return fish_open_archive_int (vpath_element->class, super);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
fish_archive_same (struct vfs_class *me, struct vfs_s_super *super,
|
fish_archive_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *super,
|
||||||
const vfs_path_t * vpath, char *op, void *cookie)
|
const vfs_path_t * vpath, void *cookie)
|
||||||
{
|
{
|
||||||
vfs_path_element_t *path_element;
|
vfs_path_element_t *path_element;
|
||||||
int result;
|
int result;
|
||||||
|
|
||||||
(void) me;
|
|
||||||
(void) vpath;
|
(void) vpath;
|
||||||
(void) cookie;
|
(void) cookie;
|
||||||
|
|
||||||
path_element = vfs_url_split (strchr (op, ':') + 1, 0, URL_NOSLASH | URL_USE_ANONYMOUS);
|
path_element =
|
||||||
|
vfs_url_split (strchr (vpath_element->raw_url_str, ':') + 1, 0,
|
||||||
|
URL_NOSLASH | URL_USE_ANONYMOUS);
|
||||||
|
|
||||||
if (path_element->user == NULL)
|
if (path_element->user == NULL)
|
||||||
path_element->user = vfs_get_local_username ();
|
path_element->user = vfs_get_local_username ();
|
||||||
|
@ -959,14 +959,14 @@ ftpfs_open_archive_int (struct vfs_class *me, struct vfs_s_super *super)
|
|||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
ftpfs_open_archive (struct vfs_class *me, struct vfs_s_super *super,
|
ftpfs_open_archive (struct vfs_s_super *super,
|
||||||
const vfs_path_t * vpath, char *op)
|
const vfs_path_t * vpath, const vfs_path_element_t * vpath_element)
|
||||||
{
|
{
|
||||||
(void) vpath;
|
(void) vpath;
|
||||||
|
|
||||||
super->data = g_new0 (ftp_super_data_t, 1);
|
super->data = g_new0 (ftp_super_data_t, 1);
|
||||||
|
|
||||||
super->path_element = ftpfs_split_url (strchr (op, ':') + 1);
|
super->path_element = ftpfs_split_url (strchr (vpath_element->raw_url_str, ':') + 1);
|
||||||
SUP->proxy = NULL;
|
SUP->proxy = NULL;
|
||||||
if (ftpfs_check_proxy (super->path_element->host))
|
if (ftpfs_check_proxy (super->path_element->host))
|
||||||
SUP->proxy = ftpfs_proxy_host;
|
SUP->proxy = ftpfs_proxy_host;
|
||||||
@ -975,25 +975,26 @@ ftpfs_open_archive (struct vfs_class *me, struct vfs_s_super *super,
|
|||||||
SUP->isbinary = TYPE_UNKNOWN;
|
SUP->isbinary = TYPE_UNKNOWN;
|
||||||
SUP->remote_is_amiga = 0;
|
SUP->remote_is_amiga = 0;
|
||||||
super->name = g_strdup ("/");
|
super->name = g_strdup ("/");
|
||||||
super->root = vfs_s_new_inode (me, super, vfs_s_default_stat (me, S_IFDIR | 0755));
|
super->root =
|
||||||
|
vfs_s_new_inode (vpath_element->class, super,
|
||||||
|
vfs_s_default_stat (vpath_element->class, S_IFDIR | 0755));
|
||||||
|
|
||||||
return ftpfs_open_archive_int (me, super);
|
return ftpfs_open_archive_int (vpath_element->class, super);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
ftpfs_archive_same (struct vfs_class *me, struct vfs_s_super *super,
|
ftpfs_archive_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *super,
|
||||||
const vfs_path_t * vpath, char *op, void *cookie)
|
const vfs_path_t * vpath, void *cookie)
|
||||||
{
|
{
|
||||||
vfs_path_element_t *path_element;
|
vfs_path_element_t *path_element;
|
||||||
int result;
|
int result;
|
||||||
|
|
||||||
(void) me;
|
|
||||||
(void) vpath;
|
(void) vpath;
|
||||||
(void) cookie;
|
(void) cookie;
|
||||||
|
|
||||||
path_element = ftpfs_split_url (strchr (op, ':') + 1);
|
path_element = ftpfs_split_url (strchr (vpath_element->raw_url_str, ':') + 1);
|
||||||
|
|
||||||
result = ((strcmp (path_element->host, super->path_element->host) == 0)
|
result = ((strcmp (path_element->host, super->path_element->host) == 0)
|
||||||
&& (strcmp (path_element->user, super->path_element->user) == 0)
|
&& (strcmp (path_element->user, super->path_element->user) == 0)
|
||||||
|
@ -287,7 +287,7 @@ tar_open_archive_int (struct vfs_class *me, const vfs_path_t * vpath, struct vfs
|
|||||||
if (result == -1)
|
if (result == -1)
|
||||||
{
|
{
|
||||||
message (D_ERROR, MSG_ERROR, _("Cannot open tar archive\n%s"), archive_name);
|
message (D_ERROR, MSG_ERROR, _("Cannot open tar archive\n%s"), archive_name);
|
||||||
g_free(archive_name);
|
g_free (archive_name);
|
||||||
ERRNOR (ENOENT, -1);
|
ERRNOR (ENOENT, -1);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -729,19 +729,17 @@ tar_read_header (struct vfs_class *me, struct vfs_s_super *archive, int tard, si
|
|||||||
* Returns 0 on success, -1 on error.
|
* Returns 0 on success, -1 on error.
|
||||||
*/
|
*/
|
||||||
static int
|
static int
|
||||||
tar_open_archive (struct vfs_class *me, struct vfs_s_super *archive, const vfs_path_t * vpath,
|
tar_open_archive (struct vfs_s_super *archive, const vfs_path_t * vpath,
|
||||||
char *op)
|
const vfs_path_element_t * vpath_element)
|
||||||
{
|
{
|
||||||
/* Initial status at start of archive */
|
/* Initial status at start of archive */
|
||||||
ReadStatus status = STATUS_EOFMARK;
|
ReadStatus status = STATUS_EOFMARK;
|
||||||
ReadStatus prev_status;
|
ReadStatus prev_status;
|
||||||
int tard;
|
int tard;
|
||||||
|
|
||||||
(void) op;
|
|
||||||
|
|
||||||
current_tar_position = 0;
|
current_tar_position = 0;
|
||||||
/* Open for reading */
|
/* Open for reading */
|
||||||
tard = tar_open_archive_int (me, vpath, archive);
|
tard = tar_open_archive_int (vpath_element->class, vpath, archive);
|
||||||
if (tard == -1)
|
if (tard == -1)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
@ -750,7 +748,7 @@ tar_open_archive (struct vfs_class *me, struct vfs_s_super *archive, const vfs_p
|
|||||||
size_t h_size;
|
size_t h_size;
|
||||||
|
|
||||||
prev_status = status;
|
prev_status = status;
|
||||||
status = tar_read_header (me, archive, tard, &h_size);
|
status = tar_read_header (vpath_element->class, archive, tard, &h_size);
|
||||||
|
|
||||||
switch (status)
|
switch (status)
|
||||||
{
|
{
|
||||||
@ -772,10 +770,10 @@ tar_open_archive (struct vfs_class *me, struct vfs_s_super *archive, const vfs_p
|
|||||||
/* Error on first record */
|
/* Error on first record */
|
||||||
case STATUS_EOFMARK:
|
case STATUS_EOFMARK:
|
||||||
{
|
{
|
||||||
char *archive_name = vfs_path_to_str(vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
message (D_ERROR, MSG_ERROR, _("%s\ndoesn't look like a tar archive."),
|
message (D_ERROR, MSG_ERROR, _("%s\ndoesn't look like a tar archive."),
|
||||||
archive_name);
|
archive_name);
|
||||||
g_free(archive_name);
|
g_free (archive_name);
|
||||||
/* FALL THRU */
|
/* FALL THRU */
|
||||||
|
|
||||||
/* Error after header rec */
|
/* Error after header rec */
|
||||||
@ -806,17 +804,14 @@ tar_open_archive (struct vfs_class *me, struct vfs_s_super *archive, const vfs_p
|
|||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static void *
|
static void *
|
||||||
tar_super_check (struct vfs_class *me, const vfs_path_t * vpath, char *op)
|
tar_super_check (const vfs_path_t * vpath)
|
||||||
{
|
{
|
||||||
static struct stat stat_buf;
|
static struct stat stat_buf;
|
||||||
char *archive_name = vfs_path_to_str(vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
int stat_result;
|
int stat_result;
|
||||||
|
|
||||||
(void) me;
|
|
||||||
(void) op;
|
|
||||||
|
|
||||||
stat_result = mc_stat (archive_name, &stat_buf);
|
stat_result = mc_stat (archive_name, &stat_buf);
|
||||||
g_free(archive_name);
|
g_free (archive_name);
|
||||||
|
|
||||||
return (stat_result != 0) ? NULL : &stat_buf;
|
return (stat_result != 0) ? NULL : &stat_buf;
|
||||||
}
|
}
|
||||||
@ -824,21 +819,20 @@ tar_super_check (struct vfs_class *me, const vfs_path_t * vpath, char *op)
|
|||||||
/* --------------------------------------------------------------------------------------------- */
|
/* --------------------------------------------------------------------------------------------- */
|
||||||
|
|
||||||
static int
|
static int
|
||||||
tar_super_same (struct vfs_class *me, struct vfs_s_super *parc,
|
tar_super_same (const vfs_path_element_t * vpath_element, struct vfs_s_super *parc,
|
||||||
const vfs_path_t * vpath, char *op, void *cookie)
|
const vfs_path_t * vpath, void *cookie)
|
||||||
{
|
{
|
||||||
struct stat *archive_stat = cookie; /* stat of main archive */
|
struct stat *archive_stat = cookie; /* stat of main archive */
|
||||||
char *archive_name = vfs_path_to_str(vpath);
|
char *archive_name = vfs_path_to_str (vpath);
|
||||||
|
|
||||||
(void) me;
|
(void) vpath_element;
|
||||||
(void) op;
|
|
||||||
|
|
||||||
if (strcmp (parc->name, archive_name) != 0)
|
if (strcmp (parc->name, archive_name) != 0)
|
||||||
{
|
{
|
||||||
g_free(archive_name);
|
g_free (archive_name);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
g_free(archive_name);
|
g_free (archive_name);
|
||||||
|
|
||||||
/* Has the cached archive been changed on the disk? */
|
/* Has the cached archive been changed on the disk? */
|
||||||
if (((tar_super_data_t *) parc->data)->st.st_mtime < archive_stat->st_mtime)
|
if (((tar_super_data_t *) parc->data)->st.st_mtime < archive_stat->st_mtime)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user