8232097: (sctp) SctpNet.init() results in java.lang.UnsatisfiedLinkError
Reviewed-by: alanb
This commit is contained in:
parent
262d5f1790
commit
180ffe5e45
src/jdk.sctp/unix/classes/sun/nio/ch/sctp
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2009, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -991,15 +991,4 @@ public class SctpMultiChannelImpl extends SctpMultiChannel
|
||||
return SctpChannelImpl.send0(fd, address, length, addr, port, assocId,
|
||||
streamNumber, unordered, ppid);
|
||||
}
|
||||
|
||||
static {
|
||||
IOUtil.load(); /* loads nio & net native libraries */
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
System.loadLibrary("sctp");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2009, 2013, Oracle and/or its affiliates. All rights reserved.
|
||||
* Copyright (c) 2009, 2019, Oracle and/or its affiliates. All rights reserved.
|
||||
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
||||
*
|
||||
* This code is free software; you can redistribute it and/or modify it
|
||||
@ -335,6 +335,14 @@ public class SctpNet {
|
||||
static native void init();
|
||||
|
||||
static {
|
||||
IOUtil.load(); // loads nio & net native libraries
|
||||
java.security.AccessController.doPrivileged(
|
||||
new java.security.PrivilegedAction<Void>() {
|
||||
public Void run() {
|
||||
System.loadLibrary("sctp");
|
||||
return null;
|
||||
}
|
||||
});
|
||||
init();
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user