Skip to content

Commit 75404d7

Browse files
Huzaif Mushtaq MirHuzaif Mushtaq Mir
authored andcommitted
chore: increase license metadata buffer size to 4096
1 parent e7c5681 commit 75404d7

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

src/main/java/com/cryptlex/lexactivator/LexActivator.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -750,14 +750,14 @@ public static FeatureEntitlement GetFeatureEntitlement(String featureName) throw
750750
public static String GetLicenseMetadata(String key) throws LexActivatorException, UnsupportedEncodingException {
751751
int status;
752752
if (Platform.isWindows()) {
753-
CharBuffer buffer = CharBuffer.allocate(256);
754-
status = LexActivatorNative.GetLicenseMetadata(new WString(key), buffer, 256);
753+
CharBuffer buffer = CharBuffer.allocate(4096);
754+
status = LexActivatorNative.GetLicenseMetadata(new WString(key), buffer, 4096);
755755
if (LA_OK == status) {
756756
return buffer.toString().trim();
757757
}
758758
} else {
759-
ByteBuffer buffer = ByteBuffer.allocate(256);
760-
status = LexActivatorNative.GetLicenseMetadata(key, buffer, 256);
759+
ByteBuffer buffer = ByteBuffer.allocate(4096);
760+
status = LexActivatorNative.GetLicenseMetadata(key, buffer, 4096);
761761
if (LA_OK == status) {
762762
return new String(buffer.array(), "UTF-8").trim();
763763
}

0 commit comments

Comments
 (0)