Fri Dec 25 21:48:51 1998 Norbert Warmuth <nwarmuth@privat.circular.de>

* vfs/direntry.c (vfs_s_new_inode): Moved initialization of st_ino
and st_dev from vfs_s_default_stat.

(vfs_s_default_stat): initialize st_ino and st_dev to zero

* vfs/tar.c (tar_open_archive): Make a new MEDATA->rdev for every
new archive.
This commit is contained in:
Norbert Warmuth 1998-12-28 10:27:07 +00:00
parent 1b248adf08
commit d2b1a29c91
3 changed files with 16 additions and 2 deletions

View File

@ -1,3 +1,13 @@
Fri Dec 25 21:48:51 1998 Norbert Warmuth <nwarmuth@privat.circular.de>
* direntry.c (vfs_s_new_inode): Moved initialization of st_ino
and st_dev from vfs_s_default_stat.
(vfs_s_default_stat): initialize st_ino and st_dev to zero
* tar.c (tar_open_archive): Make a new MEDATA->rdev for every
new archive.
Mon Dec 21 22:55:48 1998 Norbert Warmuth <nwarmuth@privat.circular.de>
* tar.c: Deleted global variable tar_gzipped_memlimit.

View File

@ -46,6 +46,8 @@ vfs_s_inode *vfs_s_new_inode (vfs *me, vfs_s_super *super, struct stat *initstat
ino->ent = NULL;
ino->flags = 0;
ino->st.st_nlink = 0;
ino->st.st_ino = MEDATA->inode_counter++;
ino->st.st_dev = MEDATA->rdev;
super->fd_usage++;
total_inodes++;
@ -146,8 +148,8 @@ struct stat *vfs_s_default_stat (vfs *me, mode_t mode)
mode &= ~myumask;
st.st_mode = mode;
st.st_ino = MEDATA->inode_counter++;
st.st_dev = MEDATA->rdev;
st.st_ino = 0;
st.st_dev = 0;
st.st_rdev = 0;
st.st_uid = getuid ();
st.st_gid = getgid ();

View File

@ -119,6 +119,8 @@ static int tar_open_archive (vfs *me, char *name, vfs_s_super *archive)
root->st.st_mode = mode;
root->u.tar.data_offset = -1;
root->st.st_nlink++;
root->st.st_dev = MEDATA->rdev++;
vfs_s_add_dots (me, root, NULL);
archive->root = root;