This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

NDK "don't fragment" flag

Hi,

I did not foud any way to set "don't fragment" flag on ip protocol.

I've tryed also the following lines without results

    val = 1;
    if(setsockopt(s, IPPROTO_IP, FLG_IPTX_DONTFRAG, &val, sizeof(val)) != 0)
        platform_write("error in setsockopt - do not fragment\n");

Does anybody found how to do that?

There is no documentation about how to set it on NDK docs. I've found FLG_IPTX_DONTFRAG on ipif.h but without any indication on using it.

I will appreciate your help a lot.

Thank you

  • Hi,

    Were you able to resolve this ? I am looping the NDK expert to help you.

    were you able to set the flag 'FLG_IPTX_DONTFRAG'? I see that if  this flag is set, then accordingly in the TX function, further processing is done. Though I am not sure if the packet is sent unfragmented, as the underlying layer's buffer should be big enough to accomodate the unfragmented packet.

    Can you explain your use case and packet sizes, so we can assit you better. Also which device are you using ?

    Thanks