diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-06 18:06:58 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-06 18:06:58 -0800 |
commit | 488b5ec871191359b9b79262a3d48456dae7ea5f (patch) | |
tree | af9d1ca5d16e7cd195cf132e7af74222dc00a6f9 /fs/9p/fid.c | |
parent | a80a438bd08827d0581fca849f3e4e539a22b39c (diff) | |
parent | 727674435470537a5e75e5f81f96d5d97de57956 (diff) | |
download | kernel_samsung_espresso10-488b5ec871191359b9b79262a3d48456dae7ea5f.zip kernel_samsung_espresso10-488b5ec871191359b9b79262a3d48456dae7ea5f.tar.gz kernel_samsung_espresso10-488b5ec871191359b9b79262a3d48456dae7ea5f.tar.bz2 |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ericvh/v9fs:
9p: fix p9_printfcall export
9p: transport API reorganization
9p: add remove function to trans_virtio
9p: Convert semaphore to spinlock for p9_idpool
9p: fix mmap to be read-only
9p: add support for sticky bit
9p: Fix soft lockup in virtio transport
9p: fix bug in attach-per-user
9p: block-based virtio client
9p: create transport rpc cut-thru
9p: fix bug in p9_clone_stat
Diffstat (limited to 'fs/9p/fid.c')
-rw-r--r-- | fs/9p/fid.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/9p/fid.c b/fs/9p/fid.c index b364da7..dfebdbe 100644 --- a/fs/9p/fid.c +++ b/fs/9p/fid.c @@ -175,7 +175,7 @@ struct p9_fid *v9fs_fid_lookup(struct dentry *dentry) if (!wnames) return ERR_PTR(-ENOMEM); - for (d = dentry, i = n; i >= 0; i--, d = d->d_parent) + for (d = dentry, i = (n-1); i >= 0; i--, d = d->d_parent) wnames[i] = (char *) d->d_name.name; clone = 1; @@ -183,7 +183,7 @@ struct p9_fid *v9fs_fid_lookup(struct dentry *dentry) while (i < n) { l = min(n - i, P9_MAXWELEM); fid = p9_client_walk(fid, l, &wnames[i], clone); - if (!fid) { + if (IS_ERR(fid)) { kfree(wnames); return fid; } |