File tree Expand file tree Collapse file tree 1 file changed +1
-9
lines changed
src/main/java/org/jruby/ext/openssl/x509store Expand file tree Collapse file tree 1 file changed +1
-9
lines changed Original file line number Diff line number Diff line change @@ -298,15 +298,7 @@ public int loadDefaultJavaCACertsFile() throws Exception {
298
298
299
299
private InputStream wrapJRubyNormalizedInputStream (String file ) throws IOException {
300
300
try {
301
- FileResource resource = JRubyFile .createResource (runtime , file );
302
- if ( ! resource .exists () ) {
303
- throw new FileNotFoundException (file + " (No such file or directory)" );
304
- }
305
- if ( resource .isDirectory () ) {
306
- throw new IOException (file + " is a directory" );
307
- }
308
- InputStream is = resource .openInputStream ();
309
- return ( is instanceof BufferedInputStream ) ? is : new BufferedInputStream (is );
301
+ return JRubyFile .createResource (runtime , file ).inputStream ();
310
302
}
311
303
catch (NoSuchMethodError e ) { // JRubyFile.createResource (JRuby < 1.7.13)
312
304
File f = new File (file );
You can’t perform that action at this time.
0 commit comments