Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1274908
| From | Sudip Mukherjee <sudipm.mukherjee@gmail.com> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH 1/3] staging: most: fix error comparison |
| Date | 2015-11-22 18:10 +0100 |
| Message-ID | <qxGjg-6O6-3@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
device_create() returns ERR_PTR on error, it does not return NULL. Signed-off-by: Sudip Mukherjee <sudip@vectorindia.org> --- drivers/staging/most/mostcore/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/most/mostcore/core.c b/drivers/staging/most/mostcore/core.c index ed1ed25..07f11dd 100644 --- a/drivers/staging/most/mostcore/core.c +++ b/drivers/staging/most/mostcore/core.c @@ -1936,7 +1936,7 @@ static int __init most_init(void) class_glue_dir = device_create(most_class, NULL, 0, NULL, "mostcore"); - if (!class_glue_dir) + if (IS_ERR(class_glue_dir)) goto exit_driver; most_aim_kset = -- 1.9.1 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread
[PATCH 1/3] staging: most: fix error comparison Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-11-22 18:10 +0100 [PATCH 3/3] staging: most: fix id leak Sudip Mukherjee <sudipm.mukherjee@gmail.com> - 2015-11-22 18:10 +0100
csiph-web