Commit 7076f440 authored by Dave Kleikamp's avatar Dave Kleikamp

Remove duplicate code in jfs_dtree.c.

It looks like I had applied a patch to the code twice, and both succeeded.
parent d755c873
...@@ -1910,22 +1910,6 @@ static int dtSplitRoot(tid_t tid, ...@@ -1910,22 +1910,6 @@ static int dtSplitRoot(tid_t tid,
rp->header.freecnt = sp->header.freecnt + rp->header.maxslot - n; rp->header.freecnt = sp->header.freecnt + rp->header.maxslot - n;
/*
* Update directory index table for entries now in right page
*/
if ((rp->header.flag & BT_LEAF) && DO_INDEX(ip)) {
metapage_t *mp = 0;
ldtentry_t *ldtentry;
stbl = DT_GETSTBL(rp);
for (n = 0; n < rp->header.nextindex; n++) {
ldtentry = (ldtentry_t *) & rp->slot[stbl[n]];
modify_index(tid, ip, le32_to_cpu(ldtentry->index),
rbn, n, &mp);
}
if (mp)
release_metapage(mp);
}
/* /*
* Update directory index table for entries now in right page * Update directory index table for entries now in right page
*/ */
...@@ -2940,12 +2924,6 @@ int jfs_readdir(struct file *filp, void *dirent, filldir_t filldir) ...@@ -2940,12 +2924,6 @@ int jfs_readdir(struct file *filp, void *dirent, filldir_t filldir)
filp->f_pos = -1; filp->f_pos = -1;
return 0; return 0;
} }
if (p->header.flag & BT_INTERNAL) {
jERROR(1,("jfs_readdir: bad index table\n"));
DT_PUTPAGE(mp);
filp->f_pos = -1;
return 0;
}
} else { } else {
if (dir_index == 0) { if (dir_index == 0) {
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment