Skip to content

Commit

Permalink
Merge branch 'upstream-master'
Browse files Browse the repository at this point in the history
  • Loading branch information
Datadog Syncup Service committed Dec 25, 2024
2 parents d40c407 + 6c59185 commit ab5081f
Show file tree
Hide file tree
Showing 8 changed files with 46 additions and 54 deletions.
38 changes: 16 additions & 22 deletions src/java.smartcardio/share/native/libj2pcsc/pcsc.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -40,15 +40,9 @@
// #define J2PCSC_DEBUG

#ifdef J2PCSC_DEBUG
#define dprintf(s) printf(s)
#define dprintf1(s, p1) printf(s, p1)
#define dprintf2(s, p1, p2) printf(s, p1, p2)
#define dprintf3(s, p1, p2, p3) printf(s, p1, p2, p3)
#define debug_printf(format, ...) printf(format, ##__VA_ARGS__)
#else
#define dprintf(s)
#define dprintf1(s, p1)
#define dprintf2(s, p1, p2)
#define dprintf3(s, p1, p2, p3)
#define debug_printf(format, ...)
#endif

#include "sun_security_smartcardio_PCSC.h"
Expand Down Expand Up @@ -112,7 +106,7 @@ JNIEXPORT jlong JNICALL Java_sun_security_smartcardio_PCSC_SCardEstablishContext
{
SCARDCONTEXT context = 0;
LONG rv;
dprintf("-establishContext\n");
debug_printf("-establishContext\n");
rv = CALL_SCardEstablishContext(dwScope, NULL, NULL, &context);
if (handleRV(env, rv)) {
return 0;
Expand Down Expand Up @@ -185,12 +179,12 @@ JNIEXPORT jobjectArray JNICALL Java_sun_security_smartcardio_PCSC_SCardListReade
DWORD size = 0;
jobjectArray result;

dprintf1("-context: %x\n", context);
debug_printf("-context: %x\n", context);
rv = CALL_SCardListReaders(context, NULL, NULL, &size);
if (handleRV(env, rv)) {
return NULL;
}
dprintf1("-size: %d\n", size);
debug_printf("-size: %d\n", size);

if (size != 0) {
mszReaders = malloc(size);
Expand All @@ -204,7 +198,7 @@ JNIEXPORT jobjectArray JNICALL Java_sun_security_smartcardio_PCSC_SCardListReade
free(mszReaders);
return NULL;
}
dprintf1("-String: %s\n", mszReaders);
debug_printf("-String: %s\n", mszReaders);
} else {
return NULL;
}
Expand All @@ -230,8 +224,8 @@ JNIEXPORT jlong JNICALL Java_sun_security_smartcardio_PCSC_SCardConnect
}
rv = CALL_SCardConnect(context, readerName, jShareMode, jPreferredProtocols, &card, &proto);
(*env)->ReleaseStringUTFChars(env, jReaderName, readerName);
dprintf1("-cardhandle: %x\n", card);
dprintf1("-protocol: %d\n", proto);
debug_printf("-cardhandle: %x\n", card);
debug_printf("-protocol: %d\n", proto);
if (handleRV(env, rv)) {
return 0;
}
Expand Down Expand Up @@ -295,9 +289,9 @@ JNIEXPORT jbyteArray JNICALL Java_sun_security_smartcardio_PCSC_SCardStatus
if (handleRV(env, rv)) {
return NULL;
}
dprintf1("-reader: %s\n", readerName);
dprintf1("-status: %d\n", state);
dprintf1("-protocol: %d\n", protocol);
debug_printf("-reader: %s\n", readerName);
debug_printf("-status: %d\n", state);
debug_printf("-protocol: %d\n", protocol);

jArray = (*env)->NewByteArray(env, atrLen);
if (jArray == NULL) {
Expand All @@ -323,7 +317,7 @@ JNIEXPORT void JNICALL Java_sun_security_smartcardio_PCSC_SCardDisconnect
LONG rv;

rv = CALL_SCardDisconnect(card, jDisposition);
dprintf1("-disconnect: 0x%X\n", rv);
debug_printf("-disconnect: 0x%X\n", rv);
handleRV(env, rv);
return;
}
Expand Down Expand Up @@ -392,7 +386,7 @@ JNIEXPORT jintArray JNICALL Java_sun_security_smartcardio_PCSC_SCardGetStatusCha
}
for (i = 0; i < readers; i++) {
jint eventStateTmp;
dprintf3("-reader status %s: 0x%X, 0x%X\n", readerState[i].szReader,
debug_printf("-reader status %s: 0x%X, 0x%X\n", readerState[i].szReader,
readerState[i].dwCurrentState, readerState[i].dwEventState);
eventStateTmp = (jint)readerState[i].dwEventState;
(*env)->SetIntArrayRegion(env, jEventState, i, 1, &eventStateTmp);
Expand All @@ -417,7 +411,7 @@ JNIEXPORT void JNICALL Java_sun_security_smartcardio_PCSC_SCardBeginTransaction
LONG rv;

rv = CALL_SCardBeginTransaction(card);
dprintf1("-beginTransaction: 0x%X\n", rv);
debug_printf("-beginTransaction: 0x%X\n", rv);
handleRV(env, rv);
return;
}
Expand All @@ -429,7 +423,7 @@ JNIEXPORT void JNICALL Java_sun_security_smartcardio_PCSC_SCardEndTransaction
LONG rv;

rv = CALL_SCardEndTransaction(card, jDisposition);
dprintf1("-endTransaction: 0x%X\n", rv);
debug_printf("-endTransaction: 0x%X\n", rv);
handleRV(env, rv);
return;
}
Expand Down
4 changes: 3 additions & 1 deletion src/jdk.compiler/share/data/symbols/java.base-O.sym.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
# ##########################################################
#
module name java.base
header exports java/io,java/lang,java/lang/annotation,java/lang/classfile,java/lang/classfile/attribute,java/lang/classfile/constantpool,java/lang/classfile/instruction,java/lang/constant,java/lang/foreign,java/lang/invoke,java/lang/module,java/lang/ref,java/lang/reflect,java/lang/runtime,java/math,java/net,java/net/spi,java/nio,java/nio/channels,java/nio/channels/spi,java/nio/charset,java/nio/charset/spi,java/nio/file,java/nio/file/attribute,java/nio/file/spi,java/security,java/security/cert,java/security/interfaces,java/security/spec,java/text,java/text/spi,java/time,java/time/chrono,java/time/format,java/time/temporal,java/time/zone,java/util,java/util/concurrent,java/util/concurrent/atomic,java/util/concurrent/locks,java/util/function,java/util/jar,java/util/random,java/util/regex,java/util/spi,java/util/stream,java/util/zip,javax/crypto,javax/crypto/interfaces,javax/crypto/spec,javax/net,javax/net/ssl,javax/security/auth,javax/security/auth/callback,javax/security/auth/login,javax/security/auth/spi,javax/security/auth/x500,javax/security/cert,jdk/internal/event[jdk.jfr],jdk/internal/javac[java.compiler\u005C;u002C;java.desktop\u005C;u002C;java.se\u005C;u002C;jdk.compiler\u005C;u002C;jdk.incubator.vector\u005C;u002C;jdk.jartool\u005C;u002C;jdk.jdeps\u005C;u002C;jdk.jfr\u005C;u002C;jdk.jlink\u005C;u002C;jdk.jshell],jdk/internal/vm/vector[jdk.incubator.vector] extraModulePackages jdk/internal/access/foreign,jdk/internal/classfile/impl,jdk/internal/constant,jdk/internal/foreign/abi,jdk/internal/foreign/abi/aarch64/linux,jdk/internal/foreign/abi/aarch64/macos,jdk/internal/foreign/abi/aarch64/windows,jdk/internal/foreign/abi/fallback,jdk/internal/foreign/abi/ppc64/aix,jdk/internal/foreign/abi/ppc64/linux,jdk/internal/foreign/abi/riscv64/linux,jdk/internal/foreign/abi/s390/linux,jdk/internal/foreign/abi/x64/sysv,jdk/internal/foreign/abi/x64/windows,jdk/internal/foreign/layout,sun/nio/ch,sun/net,jdk/internal/foreign,jdk/internal/foreign,sun/net,sun/nio/ch uses java/lang/System$LoggerFinder,java/net/ContentHandlerFactory,java/net/spi/InetAddressResolverProvider,java/net/spi/URLStreamHandlerProvider,java/nio/channels/spi/AsynchronousChannelProvider,java/nio/channels/spi/SelectorProvider,java/nio/charset/spi/CharsetProvider,java/nio/file/spi/FileSystemProvider,java/nio/file/spi/FileTypeDetector,java/security/Provider,java/text/spi/BreakIteratorProvider,java/text/spi/CollatorProvider,java/text/spi/DateFormatProvider,java/text/spi/DateFormatSymbolsProvider,java/text/spi/DecimalFormatSymbolsProvider,java/text/spi/NumberFormatProvider,java/time/chrono/AbstractChronology,java/time/chrono/Chronology,java/time/zone/ZoneRulesProvider,java/util/spi/CalendarDataProvider,java/util/spi/CalendarNameProvider,java/util/spi/CurrencyNameProvider,java/util/spi/LocaleNameProvider,java/util/spi/ResourceBundleControlProvider,java/util/spi/ResourceBundleProvider,java/util/spi/TimeZoneNameProvider,java/util/spi/ToolProvider,javax/security/auth/spi/LoginModule,jdk/internal/io/JdkConsoleProvider,jdk/internal/logger/DefaultLoggerFinder,sun/text/spi/JavaTimeDateTimePatternProvider,sun/util/locale/provider/LocaleDataMetaInfo,sun/util/resources/LocaleData$CommonResourceBundleProvider,sun/util/resources/LocaleData$SupplementaryResourceBundleProvider,sun/util/spi/CalendarProvider provides interface\u0020;java/nio/file/spi/FileSystemProvider\u0020;impls\u0020;jdk/internal/jrtfs/JrtFileSystemProvider target macos-aarch64 flags 8000
header exports java/io,java/lang,java/lang/annotation,java/lang/classfile,java/lang/classfile/attribute,java/lang/classfile/constantpool,java/lang/classfile/instruction,java/lang/constant,java/lang/foreign,java/lang/invoke,java/lang/module,java/lang/ref,java/lang/reflect,java/lang/runtime,java/math,java/net,java/net/spi,java/nio,java/nio/channels,java/nio/channels/spi,java/nio/charset,java/nio/charset/spi,java/nio/file,java/nio/file/attribute,java/nio/file/spi,java/security,java/security/cert,java/security/interfaces,java/security/spec,java/text,java/text/spi,java/time,java/time/chrono,java/time/format,java/time/temporal,java/time/zone,java/util,java/util/concurrent,java/util/concurrent/atomic,java/util/concurrent/locks,java/util/function,java/util/jar,java/util/random,java/util/regex,java/util/spi,java/util/stream,java/util/zip,javax/crypto,javax/crypto/interfaces,javax/crypto/spec,javax/net,javax/net/ssl,javax/security/auth,javax/security/auth/callback,javax/security/auth/login,javax/security/auth/spi,javax/security/auth/x500,javax/security/cert,jdk/internal/event[jdk.jfr],jdk/internal/javac[java.compiler\u005C;u002C;java.desktop\u005C;u002C;jdk.compiler\u005C;u002C;jdk.incubator.vector\u005C;u002C;jdk.jartool\u005C;u002C;jdk.jdeps\u005C;u002C;jdk.jfr\u005C;u002C;jdk.jlink\u005C;u002C;jdk.jshell],jdk/internal/vm/vector[jdk.incubator.vector] extraModulePackages jdk/internal/access/foreign,jdk/internal/classfile/impl,jdk/internal/constant,jdk/internal/foreign/abi,jdk/internal/foreign/abi/aarch64/linux,jdk/internal/foreign/abi/aarch64/macos,jdk/internal/foreign/abi/aarch64/windows,jdk/internal/foreign/abi/fallback,jdk/internal/foreign/abi/ppc64/aix,jdk/internal/foreign/abi/ppc64/linux,jdk/internal/foreign/abi/riscv64/linux,jdk/internal/foreign/abi/s390/linux,jdk/internal/foreign/abi/x64/sysv,jdk/internal/foreign/abi/x64/windows,jdk/internal/foreign/layout,sun/nio/ch,sun/net,jdk/internal/foreign,jdk/internal/foreign,sun/net,sun/nio/ch uses java/lang/System$LoggerFinder,java/net/ContentHandlerFactory,java/net/spi/InetAddressResolverProvider,java/net/spi/URLStreamHandlerProvider,java/nio/channels/spi/AsynchronousChannelProvider,java/nio/channels/spi/SelectorProvider,java/nio/charset/spi/CharsetProvider,java/nio/file/spi/FileSystemProvider,java/nio/file/spi/FileTypeDetector,java/security/Provider,java/text/spi/BreakIteratorProvider,java/text/spi/CollatorProvider,java/text/spi/DateFormatProvider,java/text/spi/DateFormatSymbolsProvider,java/text/spi/DecimalFormatSymbolsProvider,java/text/spi/NumberFormatProvider,java/time/chrono/AbstractChronology,java/time/chrono/Chronology,java/time/zone/ZoneRulesProvider,java/util/spi/CalendarDataProvider,java/util/spi/CalendarNameProvider,java/util/spi/CurrencyNameProvider,java/util/spi/LocaleNameProvider,java/util/spi/ResourceBundleControlProvider,java/util/spi/ResourceBundleProvider,java/util/spi/TimeZoneNameProvider,java/util/spi/ToolProvider,javax/security/auth/spi/LoginModule,jdk/internal/io/JdkConsoleProvider,jdk/internal/logger/DefaultLoggerFinder,sun/text/spi/JavaTimeDateTimePatternProvider,sun/util/locale/provider/LocaleDataMetaInfo,sun/util/resources/LocaleData$CommonResourceBundleProvider,sun/util/resources/LocaleData$SupplementaryResourceBundleProvider,sun/util/spi/CalendarProvider provides interface\u0020;java/nio/file/spi/FileSystemProvider\u0020;impls\u0020;jdk/internal/jrtfs/JrtFileSystemProvider target macos-aarch64 flags 8000

class name java/io/BufferedInputStream
-method name read descriptor ()I
Expand Down Expand Up @@ -970,9 +970,11 @@ header extends java/lang/Object implements java/lang/classfile/ClassFileTransfor

class name java/lang/classfile/CompoundElement
header extends java/lang/Object implements java/lang/classfile/ClassFileElement,java/lang/Iterable sealed true permittedSubclasses java/lang/classfile/ClassModel,java/lang/classfile/CodeModel,java/lang/classfile/FieldModel,java/lang/classfile/MethodModel,jdk/internal/classfile/impl/AbstractUnboundModel flags 601 signature <E::Ljava/lang/classfile/ClassFileElement;>Ljava/lang/Object;Ljava/lang/classfile/ClassFileElement;Ljava/lang/Iterable<TE;>;
innerclass innerClass java/lang/invoke/MethodHandles$Lookup outerClass java/lang/invoke/MethodHandles innerClassName Lookup flags 19
-method name forEachElement descriptor (Ljava/util/function/Consumer;)V
-method name elements descriptor ()Ljava/lang/Iterable;
method name forEach descriptor (Ljava/util/function/Consumer;)V flags 401 signature (Ljava/util/function/Consumer<-TE;>;)V
method name toDebugString descriptor ()Ljava/lang/String; flags 1

class name java/lang/classfile/CustomAttribute
header extends java/lang/Object implements java/lang/classfile/Attribute,java/lang/classfile/CodeElement,java/lang/classfile/ClassElement,java/lang/classfile/MethodElement,java/lang/classfile/FieldElement flags 421 signature <T:Ljava/lang/classfile/CustomAttribute<TT;>;>Ljava/lang/Object;Ljava/lang/classfile/Attribute<TT;>;Ljava/lang/classfile/CodeElement;Ljava/lang/classfile/ClassElement;Ljava/lang/classfile/MethodElement;Ljava/lang/classfile/FieldElement;
Expand Down
2 changes: 1 addition & 1 deletion src/jdk.compiler/share/data/symbols/java.se-O.sym.txt
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,5 @@
# ##########################################################
#
module name java.se
header requires name\u0020;java.base\u0020;flags\u0020;20,name\u0020;java.compiler\u0020;flags\u0020;20,name\u0020;java.datatransfer\u0020;flags\u0020;20,name\u0020;java.desktop\u0020;flags\u0020;20,name\u0020;java.instrument\u0020;flags\u0020;20,name\u0020;java.logging\u0020;flags\u0020;20,name\u0020;java.management\u0020;flags\u0020;20,name\u0020;java.management.rmi\u0020;flags\u0020;20,name\u0020;java.naming\u0020;flags\u0020;20,name\u0020;java.net.http\u0020;flags\u0020;20,name\u0020;java.prefs\u0020;flags\u0020;20,name\u0020;java.rmi\u0020;flags\u0020;20,name\u0020;java.scripting\u0020;flags\u0020;20,name\u0020;java.security.jgss\u0020;flags\u0020;20,name\u0020;java.security.sasl\u0020;flags\u0020;20,name\u0020;java.sql\u0020;flags\u0020;20,name\u0020;java.sql.rowset\u0020;flags\u0020;20,name\u0020;java.transaction.xa\u0020;flags\u0020;20,name\u0020;java.xml\u0020;flags\u0020;20,name\u0020;java.xml.crypto\u0020;flags\u0020;20 target macos-aarch64 flags 8000 classAnnotations @Ljdk/internal/javac/ParticipatesInPreview;
header requires name\u0020;java.base\u0020;flags\u0020;20,name\u0020;java.compiler\u0020;flags\u0020;20,name\u0020;java.datatransfer\u0020;flags\u0020;20,name\u0020;java.desktop\u0020;flags\u0020;20,name\u0020;java.instrument\u0020;flags\u0020;20,name\u0020;java.logging\u0020;flags\u0020;20,name\u0020;java.management\u0020;flags\u0020;20,name\u0020;java.management.rmi\u0020;flags\u0020;20,name\u0020;java.naming\u0020;flags\u0020;20,name\u0020;java.net.http\u0020;flags\u0020;20,name\u0020;java.prefs\u0020;flags\u0020;20,name\u0020;java.rmi\u0020;flags\u0020;20,name\u0020;java.scripting\u0020;flags\u0020;20,name\u0020;java.security.jgss\u0020;flags\u0020;20,name\u0020;java.security.sasl\u0020;flags\u0020;20,name\u0020;java.sql\u0020;flags\u0020;20,name\u0020;java.sql.rowset\u0020;flags\u0020;20,name\u0020;java.transaction.xa\u0020;flags\u0020;20,name\u0020;java.xml\u0020;flags\u0020;20,name\u0020;java.xml.crypto\u0020;flags\u0020;20 target macos-aarch64 flags 8000

26 changes: 13 additions & 13 deletions src/jdk.crypto.cryptoki/share/native/libj2pkcs11/j2secmod.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -52,7 +52,7 @@ JNIEXPORT jboolean JNICALL Java_sun_security_pkcs11_Secmod_nssVersionCheck
}

res = versionCheck(requiredVersion);
dprintf2("-version >=%s: %d\n", requiredVersion, res);
debug_printf("-version >=%s: %d\n", requiredVersion, res);
(*env)->ReleaseStringUTFChars(env, jVersion, requiredVersion);

return (res == 0) ? JNI_FALSE : JNI_TRUE;
Expand Down Expand Up @@ -146,11 +146,11 @@ JNIEXPORT jboolean JNICALL Java_sun_security_pkcs11_Secmod_nssInitialize
if (configDir != NULL) {
(*env)->ReleaseStringUTFChars(env, jConfigDir, configDir);
}
dprintf1("-res: %d\n", res);
debug_printf("-res: %d\n", res);
#ifdef SECMOD_DEBUG
if (res == -1) {
if (getError != NULL) {
dprintf1("-NSS error: %d\n", getError());
debug_printf("-NSS error: %d\n", getError());
}
}
#endif // SECMOD_DEBUG
Expand All @@ -173,12 +173,12 @@ JNIEXPORT jobject JNICALL Java_sun_security_pkcs11_Secmod_nssGetModuleList
jint i, jSlotID;

if (getModuleList == NULL) {
dprintf("-getmodulelist function not found\n");
debug_printf("-getmodulelist function not found\n");
return NULL;
}
list = getModuleList();
if (list == NULL) {
dprintf("-module list is null\n");
debug_printf("-module list is null\n");
return NULL;
}

Expand Down Expand Up @@ -211,12 +211,12 @@ JNIEXPORT jobject JNICALL Java_sun_security_pkcs11_Secmod_nssGetModuleList
while (list != NULL) {
module = list->module;
// assert module != null
dprintf1("-commonname: %s\n", module->commonName);
dprintf1("-dllname: %s\n", (module->dllName != NULL) ? module->dllName : "NULL");
dprintf1("-slots: %d\n", module->slotCount);
dprintf1("-loaded: %d\n", module->loaded);
dprintf1("-internal: %d\n", module->internal);
dprintf1("-fips: %d\n", module->isFIPS);
debug_printf("-commonname: %s\n", module->commonName);
debug_printf("-dllname: %s\n", (module->dllName != NULL) ? module->dllName : "NULL");
debug_printf("-slots: %d\n", module->slotCount);
debug_printf("-loaded: %d\n", module->loaded);
debug_printf("-internal: %d\n", module->internal);
debug_printf("-fips: %d\n", module->isFIPS);
jCommonName = (*env)->NewStringUTF(env, module->commonName);
if (jCommonName == NULL) {
return NULL;
Expand Down Expand Up @@ -248,7 +248,7 @@ JNIEXPORT jobject JNICALL Java_sun_security_pkcs11_Secmod_nssGetModuleList
}
list = list->next;
}
dprintf("-ok\n");
debug_printf("-ok\n");

return jList;
}
12 changes: 3 additions & 9 deletions src/jdk.crypto.cryptoki/share/native/libj2pkcs11/j2secmod.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -37,15 +37,9 @@
void *p11FindFunction(JNIEnv *env, jlong jHandle, const char *functionName);

#ifdef SECMOD_DEBUG
#define dprintf(s) printf(s)
#define dprintf1(s, p1) printf(s, p1)
#define dprintf2(s, p1, p2) printf(s, p1, p2)
#define dprintf3(s, p1, p2, p3) printf(s, p1, p2, p3)
#define debug_printf(format, ...) printf(format, ##__VA_ARGS__)
#else
#define dprintf(s)
#define dprintf1(s, p1)
#define dprintf2(s, p1, p2)
#define dprintf3(s, p1, p2, p3)
#define debug_printf(format, ...)
#endif

// NSS types
Expand Down
8 changes: 4 additions & 4 deletions src/jdk.crypto.cryptoki/unix/native/libj2pkcs11/j2secmod_md.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2005, 2023, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2005, 2024, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -61,7 +61,7 @@ JNIEXPORT jlong JNICALL Java_sun_security_pkcs11_Secmod_nssGetLibraryHandle
#else
hModule = dlopen(libName, RTLD_NOLOAD);
#endif
dprintf2("-handle for %s: %u\n", libName, hModule);
debug_printf("-handle for %s: %u\n", libName, hModule);
(*env)->ReleaseStringUTFChars(env, jLibName, libName);
return ptr_to_jlong(hModule);
}
Expand All @@ -75,10 +75,10 @@ JNIEXPORT jlong JNICALL Java_sun_security_pkcs11_Secmod_nssLoadLibrary
return 0L;
}

dprintf1("-lib %s\n", libName);
debug_printf("-lib %s\n", libName);
hModule = dlopen(libName, RTLD_LAZY);
(*env)->ReleaseStringUTFChars(env, jLibName, libName);
dprintf2("-handle: %u (0X%X)\n", hModule, hModule);
debug_printf("-handle: %u (0X%X)\n", hModule, hModule);

if (hModule == NULL) {
p11ThrowIOException(env, dlerror());
Expand Down
Loading

0 comments on commit ab5081f

Please sign in to comment.