@@ -224,10 +224,14 @@ public static void load(String originalName, ClassLoader loader) { |
224 | 224 | // Pass "io.netty.native.workdir" as an argument to allow shading tools to see |
225 | 225 | // the string. Since this is printed out to users to tell them what to do next, |
226 | 226 | // we want the value to be correct even when shading. |
227 | | - logger.info("{} exists but cannot be executed even when execute permissions set; " + |
228 | | - "check volume for \"noexec\" flag; use -D{}=[path] " + |
229 | | - "to set native working directory separately.", |
230 | | - tmpFile.getPath(), "io.netty.native.workdir"); |
| 227 | + String message = String.format( |
| 228 | + "%s exists but cannot be executed even when execute permissions set; " + |
| 229 | + "check volume for \"noexec\" flag; use -D%s=[path] " + |
| 230 | + "to set native working directory separately.", |
| 231 | + tmpFile.getPath(), "io.netty.native.workdir"); |
| 232 | + logger.info(message); |
| 233 | + suppressed.add(ThrowableUtil.unknownStackTrace( |
| 234 | + new UnsatisfiedLinkError(message), NativeLibraryLoader.class, "load")); |
231 | 235 | } |
232 | 236 | } catch (Throwable t) { |
233 | 237 | suppressed.add(t); |
@@ -410,7 +414,7 @@ private static void loadLibraryByHelper(final Class<?> helper, final String name |
410 | 414 | @Override |
411 | 415 | public Object run() { |
412 | 416 | try { |
413 | | - // Invoke the helper to load the native library, if succeed, then the native |
| 417 | + // Invoke the helper to load the native library, if it succeeds, then the native |
414 | 418 | // library belong to the specified ClassLoader. |
415 | 419 | Method method = helper.getMethod("loadLibrary", String.class, boolean.class); |
416 | 420 | method.setAccessible(true); |
|