prepSendFd() — netty Function Reference
Architecture documentation for the prepSendFd() function in MsgHdr.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 1c0c157c_7d1a_fcb5_0464_ea2479cedb64["prepSendFd()"] 4a81f547_d99c_c526_30f9_847735bb8edf["MsgHdr"] 1c0c157c_7d1a_fcb5_0464_ea2479cedb64 -->|defined in| 4a81f547_d99c_c526_30f9_847735bb8edf style 1c0c157c_7d1a_fcb5_0464_ea2479cedb64 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
transport-classes-io_uring/src/main/java/io/netty/channel/uring/MsgHdr.java lines 92–109
static void prepSendFd(ByteBuffer memory, int fd, ByteBuffer msgControl,
int cmsgHdrDataOffset, ByteBuffer iovMemory, int iovLength) {
int memoryPosition = memory.position();
long msgControlAddr = Buffer.memoryAddress(msgControl);
CmsgHdr.writeScmRights(msgControl, cmsgHdrDataOffset, fd);
if (Native.SIZEOF_SIZE_T == 4) {
memory.putInt(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_CONTROL, (int) msgControlAddr);
memory.putInt(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_CONTROLLEN, Native.MSG_CONTROL_LEN_FOR_FD);
memory.putInt(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_IOV, (int) Buffer.memoryAddress(iovMemory));
memory.putInt(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_IOVLEN, iovLength);
} else {
assert Native.SIZEOF_SIZE_T == 8;
memory.putLong(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_CONTROL, msgControlAddr);
memory.putLong(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_CONTROLLEN, Native.MSG_CONTROL_LEN_FOR_FD);
memory.putLong(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_IOV, Buffer.memoryAddress(iovMemory));
memory.putLong(memoryPosition + Native.MSGHDR_OFFSETOF_MSG_IOVLEN, iovLength);
}
}
Domain
Subdomains
Source
Frequently Asked Questions
What does prepSendFd() do?
prepSendFd() is a function in the netty codebase, defined in transport-classes-io_uring/src/main/java/io/netty/channel/uring/MsgHdr.java.
Where is prepSendFd() defined?
prepSendFd() is defined in transport-classes-io_uring/src/main/java/io/netty/channel/uring/MsgHdr.java at line 92.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free