File tree 2 files changed +8
-5
lines changed
contrib/platform/src/com/sun/jna/platform/win32
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ Features
11
11
12
12
Bug Fixes
13
13
---------
14
+ * [ #1644 ] ( https://github.com/java-native-access/jna/issues/1644 ) : Fix bug in VARDESC causing an illegal memory access - [ @stmuecke ] ( https://github.com/stmuecke )
14
15
15
16
Release 5.15.0
16
17
==============
Original file line number Diff line number Diff line change @@ -1398,14 +1398,10 @@ public static class ByReference extends _VARDESC implements
1398
1398
public VARIANT .ByReference lpvarValue ;
1399
1399
1400
1400
public _VARDESC () {
1401
- setType ("lpvarValue" );
1402
- this .read ();
1403
1401
}
1404
1402
1405
1403
public _VARDESC (Pointer pointer ) {
1406
1404
super (pointer );
1407
- setType ("lpvarValue" );
1408
- this .read ();
1409
1405
}
1410
1406
1411
1407
/**
@@ -1431,9 +1427,15 @@ public VARDESC() {
1431
1427
1432
1428
public VARDESC (Pointer pointer ) {
1433
1429
super (pointer );
1434
- this ._vardesc .setType ("lpvarValue" );
1435
1430
this .read ();
1436
1431
}
1432
+
1433
+ @ Override
1434
+ public void read () {
1435
+ readField ("varkind" );
1436
+ this ._vardesc .setType (varkind .value == VARKIND .VAR_CONST ? "lpvarValue" : "oInst" );
1437
+ super .read ();
1438
+ }
1437
1439
}
1438
1440
1439
1441
@ FieldOrder ({"tdesc" , "_elemdesc" })
You can’t perform that action at this time.
0 commit comments