File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
test/jdk/sun/security/pkcs11/Serialize Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright (c) 2003, 2018 , Oracle and/or its affiliates. All rights reserved.
2
+ * Copyright (c) 2003, 2025 , Oracle and/or its affiliates. All rights reserved.
3
3
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4
4
*
5
5
* This code is free software; you can redistribute it and/or modify it
41
41
public class SerializeProvider extends PKCS11Test {
42
42
43
43
public void main (Provider p ) throws Exception {
44
+
44
45
if (Security .getProvider (p .getName ()) != p ) {
45
- System .out .println ("Provider not installed in Security, skipping" );
46
- return ;
46
+ Security .addProvider (p );
47
47
}
48
48
49
49
ByteArrayOutputStream out = new ByteArrayOutputStream ();
@@ -57,7 +57,7 @@ public void main(Provider p) throws Exception {
57
57
InputStream in = new ByteArrayInputStream (data );
58
58
ObjectInputStream oin = new ObjectInputStream (in );
59
59
60
- Provider p2 = (Provider )oin .readObject ();
60
+ Provider p2 = (Provider ) oin .readObject ();
61
61
62
62
System .out .println ("Reconstituted: " + p2 );
63
63
You can’t perform that action at this time.
0 commit comments