mirror of
https://github.com/mitb-archive/filebot
synced 2024-12-23 16:28:51 -05:00
* improve MediaInfoException text
This commit is contained in:
parent
9a663ea711
commit
e6dbd4538e
@ -5,13 +5,13 @@ import com.sun.jna.Platform;
|
||||
public class MediaInfoException extends RuntimeException {
|
||||
|
||||
public MediaInfoException(LinkageError e) {
|
||||
super(getLinkageErrorMessage(e));
|
||||
super(getLinkageErrorMessage(e), e);
|
||||
}
|
||||
|
||||
private static String getLinkageErrorMessage(LinkageError e) {
|
||||
String name = Platform.isWindows() ? "MediaInfo.dll" : Platform.isMac() ? "libmediainfo.dylib" : "libmediainfo.so";
|
||||
String arch = System.getProperty("os.arch").toLowerCase().trim();
|
||||
return String.format("Unable to load %s native library %s", arch, name);
|
||||
String arch = System.getProperty("os.arch");
|
||||
return String.format("Unable to load %s native library %s: %s", arch, name, e.getMessage());
|
||||
}
|
||||
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user