[7.1.0] Treat the inability to load the Windows filesystem JNI as an error. (#21090)
Unlike on Unix, we can't fall back to an alternative implementation. Failure to emit an early error would cause later native method calls to produce a less informative error message. See https://github.com/bazelbuild/bazel/issues/20677 for a recent example where this would have been helpful. Also note some minor changes: * Since we attempt to load the JNI in two different ways, make sure to propagate both exceptions (one suppressed by the other). * The default switch case is unnecessary, as errorprone already enforces exhaustiveness. PiperOrigin-RevId: 595206761 Change-Id: I4b6258d59d9a4fcc9f83418375acc51a32d7f4a4
Showing
- src/main/java/com/google/devtools/build/lib/bazel/BazelFileSystemModule.java 11 additions, 0 deletions...oogle/devtools/build/lib/bazel/BazelFileSystemModule.java
- src/main/java/com/google/devtools/build/lib/jni/BUILD 1 addition, 0 deletionssrc/main/java/com/google/devtools/build/lib/jni/BUILD
- src/main/java/com/google/devtools/build/lib/jni/JniLoader.java 21 additions, 17 deletions...ain/java/com/google/devtools/build/lib/jni/JniLoader.java
- src/main/protobuf/failure_details.proto 1 addition, 0 deletionssrc/main/protobuf/failure_details.proto
Please register or sign in to comment