patch-2.4.0-test3 linux/fs/umsdos/ioctl.c
Next file: linux/fs/umsdos/namei.c
Previous file: linux/fs/umsdos/inode.c
Back to the patch index
Back to the overall index
- Lines: 43
- Date:
Wed Jul 5 21:38:48 2000
- Orig file:
v2.4.0-test2/linux/fs/umsdos/ioctl.c
- Orig date:
Tue May 23 15:31:36 2000
diff -u --recursive --new-file v2.4.0-test2/linux/fs/umsdos/ioctl.c linux/fs/umsdos/ioctl.c
@@ -75,7 +75,6 @@
struct dentry *dentry = filp->f_dentry;
struct umsdos_ioctl *idata = (struct umsdos_ioctl *) data_ptr;
int ret;
- struct file new_filp;
struct umsdos_ioctl data;
Printk(("UMSDOS_ioctl_dir: %s/%s, cmd=%d, data=%08lx\n",
@@ -161,6 +160,7 @@
* Return > 0 if success.
*/
struct dentry *demd;
+ loff_t pos = filp->f_pos;
/* The absence of the EMD is simply seen as an EOF */
demd = umsdos_get_emd_dentry(dentry);
@@ -171,14 +171,12 @@
if (!demd->d_inode)
goto read_dput;
- fill_new_filp(&new_filp, demd);
- new_filp.f_pos = filp->f_pos;
- while (new_filp.f_pos < demd->d_inode->i_size) {
- off_t f_pos = new_filp.f_pos;
+ while (pos < demd->d_inode->i_size) {
+ off_t f_pos = pos;
struct umsdos_dirent entry;
struct umsdos_info info;
- ret = umsdos_emd_dir_readentry (&new_filp, &entry);
+ ret = umsdos_emd_dir_readentry (demd, &pos, &entry);
if (ret)
break;
if (entry.name_len <= 0)
@@ -199,7 +197,7 @@
break;
}
/* update the original f_pos */
- filp->f_pos = new_filp.f_pos;
+ filp->f_pos = pos;
read_dput:
d_drop(demd);
dput(demd);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)