Skip to content

Commit

Permalink
9p: Correct fidpool creation failure in p9_client_create
Browse files Browse the repository at this point in the history
On error, p9_idpool_create returns an ERR_PTR-encoded errno.

Signed-off-by: Josef 'Jeff' Sipek <jeffpc@josefsipek.net>
Acked-by: Eric Van Hensbergen <ericvh@gmail.com>
  • Loading branch information
Josef 'Jeff' Sipek authored and Eric Van Hensbergen committed May 15, 2008
1 parent c154949 commit 728fc4e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/9p/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ struct p9_client *p9_client_create(const char *dev_name, char *options)
spin_lock_init(&clnt->lock);
INIT_LIST_HEAD(&clnt->fidlist);
clnt->fidpool = p9_idpool_create();
if (!clnt->fidpool) {
if (IS_ERR(clnt->fidpool)) {
err = PTR_ERR(clnt->fidpool);
clnt->fidpool = NULL;
goto error;
Expand Down

0 comments on commit 728fc4e

Please sign in to comment.