genodelabs / genode-world

Collection of community-maintained components for Genode
Other
44 stars 46 forks source link

jdk: remove use of obsoleted libc-plugin interface #324

Closed nfeske closed 1 year ago

nfeske commented 1 year ago

The code at https://github.com/genodelabs/genode-world/blob/master/src/app/jdk/lib/jvm/dummies.cpp#L102 calls an obsoleted libc-internal interface:

    /*
     * socketpair() is used in libnio/libnet to create "marker FDs", which are
     * only used as destination FD in dup2(). So it is safe to just reserve
     * those descriptors here.
     */
    sv[0] = Libc::file_descriptor_allocator()->alloc(nullptr, nullptr)->libc_fd;
    sv[1] = Libc::file_descriptor_allocator()->alloc(nullptr, nullptr)->libc_fd;

As the removal of the interface will break the build, can this problem be solved in another way? Maybe opening a pseudo file like /dev/null could do the trick?

chelmuth commented 1 year ago

Related to genodelabs/genode#3770