[PATCH 1/2] libkmod: return errno from index_mm_open on resource load fail

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Trust this value, instead of injecting our own, as this could be
something as simple as ENOENT, rather than an alarming ENOMEM.
---
 libkmod/libkmod.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libkmod/libkmod.c b/libkmod/libkmod.c
index b3e1d6b..0d9cd80 100644
--- a/libkmod/libkmod.c
+++ b/libkmod/libkmod.c
@@ -816,7 +816,7 @@ KMOD_EXPORT int kmod_load_resources(struct kmod_ctx *ctx)
 
 fail:
 	kmod_unload_resources(ctx);
-	return -ENOMEM;
+	return -errno;
 }
 
 /**
-- 
1.8.1.1

--
To unsubscribe from this list: send the line "unsubscribe linux-modules" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux