38 lines
1.2 KiB
Diff
38 lines
1.2 KiB
Diff
|
From a4e54de2e1ddbf7bd52e2b2e9857402ad93d5286 Mon Sep 17 00:00:00 2001
|
||
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||
|
Date: Wed, 25 Jul 2018 09:28:04 +0100
|
||
|
Subject: [PATCH] vddk: Improve error message if the proprietary library cannot
|
||
|
be found.
|
||
|
|
||
|
(cherry picked from commit 94e791f87c6029983befa6199771345fd9cdfcc9)
|
||
|
---
|
||
|
plugins/vddk/vddk.c | 8 ++++++--
|
||
|
1 file changed, 6 insertions(+), 2 deletions(-)
|
||
|
|
||
|
diff --git a/plugins/vddk/vddk.c b/plugins/vddk/vddk.c
|
||
|
index e8b1be5..67aaa61 100644
|
||
|
--- a/plugins/vddk/vddk.c
|
||
|
+++ b/plugins/vddk/vddk.c
|
||
|
@@ -142,12 +142,16 @@ error_function (const char *fs, va_list args)
|
||
|
static void
|
||
|
vddk_load (void)
|
||
|
{
|
||
|
- const char *soname = "libvixDiskLib.so.6";
|
||
|
+ static const char soname[] = "libvixDiskLib.so.6";
|
||
|
|
||
|
/* Load the plugin and set the entry points. */
|
||
|
dl = dlopen (soname, RTLD_NOW);
|
||
|
if (dl == NULL) {
|
||
|
- nbdkit_error ("%s: %s", soname, dlerror ());
|
||
|
+ nbdkit_error ("%s\n\n"
|
||
|
+ "If '%s' is located on a non-standard path you may need to\n"
|
||
|
+ "set $LD_LIBRARY_PATH or edit /etc/ld.so.conf.\n\n"
|
||
|
+ "See the nbdkit-vddk-plugin(1) man page for details.",
|
||
|
+ dlerror (), soname);
|
||
|
exit (EXIT_FAILURE);
|
||
|
}
|
||
|
|
||
|
--
|
||
|
1.8.3.1
|
||
|
|