Skip to content

DirectArgumentsMarshalNullableTest failure for s390x #1103

@nealef

Description

@nealef
  1. Version of JNA and related jars
    • From git master
  2. Version and vendor of the java virtual machine
    • openJDK 11 (Eclipse openJ9)
  3. Operating system
    • Linux
  4. System architecture (CPU type, bitness of the JVM):
    • s390x (64-bit, big endian)
  5. Complete description of the problem
    • DirectArgumentsMarshalNullableTest test fails:
    [junit] Testcase: testIntegerType(com.sun.jna.DirectArgumentsMarshalNullableTest):	FAILED
    [junit] Basic non-null call expected:<42> but was:<0>
    [junit] junit.framework.AssertionFailedError: Basic non-null call expected:<42> but was:<0>
    [junit] 	at com.sun.jna.ArgumentsMarshalNullableTest.testIntegerType(ArgumentsMarshalNullableTest.java:214)
    [junit] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    [junit] 	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    [junit] 	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
  1. Steps to reproduce
  • Build using ant 1.10.6

I inserted some debug code into DirectArgumentsMarshalNullableTest and into native/testlib.c to see what was being processed:

  1. Value of Int32.fromNative/toNative -
    [junit] from: com.sun.jna.ArgumentsMarshalNullableTest$Int32$1@7567860b
    [junit] to:   com.sun.jna.ArgumentsMarshalNullableTest$Int32$2@ae757b28
    [junit] from: com.sun.jna.ArgumentsMarshalNullableTest$Int32$1@7567860b
    [junit] from: com.sun.jna.ArgumentsMarshalNullableTest$Int32$1@7567860b
    [junit] to:   com.sun.jna.ArgumentsMarshalNullableTest$Int32$2@ae757b28
    [junit] to:   com.sun.jna.ArgumentsMarshalNullableTest$Int32$2@ae757b28
  1. Value of arg in returnInt32Argument
    [junit] int32arg: 0000002a
    [junit] int32arg: 00000000
    [junit] int32arg: 00000000
    [junit] int32arg: 0000002a
    [junit] int32arg: 00000000

Note: All other tests pass.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions