summaryrefslogtreecommitdiff
path: root/usr/src
diff options
context:
space:
mode:
authorMike Christensen <Michael.Christensen@Sun.COM>2010-07-26 14:06:42 -0700
committerMike Christensen <Michael.Christensen@Sun.COM>2010-07-26 14:06:42 -0700
commit1a024a4828552f36f41749085bad547c64a0f0a6 (patch)
tree929214f5d8b278a2ee7918ddb4c90f033c6d02e1 /usr/src
parent3dbbe3fb79c81fac93e4001bdf68eb06c8a086e8 (diff)
downloadillumos-gate-1a024a4828552f36f41749085bad547c64a0f0a6.tar.gz
6971450 virtinfo core dumps on SIGSEGV if libds does not exist
Diffstat (limited to 'usr/src')
-rw-r--r--usr/src/lib/libv12n/sparc/libv12n.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/usr/src/lib/libv12n/sparc/libv12n.c b/usr/src/lib/libv12n/sparc/libv12n.c
index 8a2dd7892a..3fbfdf267c 100644
--- a/usr/src/lib/libv12n/sparc/libv12n.c
+++ b/usr/src/lib/libv12n/sparc/libv12n.c
@@ -19,8 +19,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2010 Sun Microsystems, Inc. All rights reserved.
- * Use is subject to license terms.
+ * Copyright (c) 2010, Oracle and/or its affiliates. All rights reserved.
*/
#include <dlfcn.h>
@@ -722,8 +721,10 @@ v12n_get_ldma_system_msg(int msgtype, char **strp)
* 'agent-system' client registration/message at a time.
*/
(void) mutex_lock(&v12n_ldma_lock);
- if ((err = v12n_libds_init()) != 0)
- goto done;
+ if ((err = v12n_libds_init()) != 0) {
+ (void) mutex_unlock(&v12n_ldma_lock);
+ return (err);
+ }
v12n_ldma_msgtype = msgtype;
v12n_ldma_msgstr = NULL;