Skip to content

fun address is the same after Multiple load In Ubuntu #143

Open
@Terrency

Description

@Terrency

we loaded same so with different name twice, and found that normal function address is the same in Linux environment

        MyLibrary libc = LibraryLoader.create(MyLibrary.class).load("testjnr");
        MyLibrary1 libc1 = LibraryLoader.create(MyLibrary1.class).load("testjnr1");
static int func1()
{
	return 0;
}

int func2()
{
	return 1;
}

we print address of func1 in Windows and Ubuntu, it is different address in memory
but address of func2 is the same in Ubuntu, it is different in Windows.
it seem that normal function could be override by loading in Ubuntu and CentOS.
could some one help to fix this bug.
we try the sample with JNI, JNI is OK.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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