Skip to content

Commit aa9f9a2

Browse files
committed
use NotImplementedError instead of LoadError + assume little attrs
1 parent 819559a commit aa9f9a2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/main/java/org/jruby/ext/openssl/X509Request.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public static void createRequest(final Ruby runtime, final RubyModule _X509) {
9494

9595
public X509Request(Ruby runtime, RubyClass type) {
9696
super(runtime, type);
97-
attributes = new ArrayList<X509Attribute>();
97+
attributes = new ArrayList<X509Attribute>(4);
9898
}
9999

100100
@JRubyMethod(name = "initialize", rest = true, visibility = Visibility.PRIVATE)
@@ -128,7 +128,7 @@ else if ( "DSA".equalsIgnoreCase(algorithm) ) {
128128
this.public_key = newPKeyImplInstance(context, "DSA", enc);
129129
}
130130
else {
131-
throw runtime.newLoadError("not implemented algo for public key: " + algorithm);
131+
throw runtime.newNotImplementedError("public key algorithm: " + algorithm);
132132
}
133133

134134
this.subject = newName( context, request.getSubject() );

0 commit comments

Comments
 (0)