feat: add try catch block

This commit is contained in:
Samuel Fernandes 2025-02-05 23:29:32 +00:00 committed by GitHub
parent 61ad7a70b1
commit 05b4000863
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -232,8 +232,14 @@ public class OSInfo {
} }
private static boolean isMusl() { private static boolean isMusl() {
try {
return new File("/lib/ld-musl-x86_64.so.1").exists(); return new File("/lib/ld-musl-x86_64.so.1").exists();
} }
catch (Exception e) {
System.err.println("Error while checking if ld-musl-x86_64.so.1 exists");
return false;
}
}
static String translateOSNameToFolderName(String osName) { static String translateOSNameToFolderName(String osName) {
if(osName.contains("Windows")) { if(osName.contains("Windows")) {