home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!sun-barr!cs.utexas.edu!zaphod.mps.ohio-state.edu!magnus.acs.ohio-state.edu!usenet.ins.cwru.edu!agate!doc.ic.ac.uk!uknet!mucs!m1!qinyi
- From: qinyi@uk.ac.man.cs (Yi Qin (BCW PhD))
- Newsgroups: comp.unix.programmer
- Subject: UDP packt size limit (SunOS4.1)
- Message-ID: <QINYI.92Nov18184428@r6m.uk.ac.man.cs>
- Date: 18 Nov 92 18:44:28 GMT
- Sender: news@cs.man.ac.uk
- Organization: University of Manchester, UK
- Lines: 33
-
-
- Hello.
-
- It seems to me that this UDP packet size limit is not documented
- in any manual or references for SunOS 4.1. So far as I understand,
- the UDP layer only does very simple header treatment of IP packets
- and does not break the IP packet. So the UDP maximum packet size
- should be the same as that of IP packets, being 65535.
-
- Now I face the following situation. If I define the size of a data-
- gram packet to be 9008 (9000 * sizeof(char) + 2 * sizeof(int)). The call
- to sendto() returns with an error saying message to long. When I
- sendto() and recvfrom() a message of size 8816, it works OK for me.
- The intereting thing is, when I use the size of 8817 (8809 + 8),
- the message is recvfrom()'ed (the number of bytes returned is the
- same as that indicated in the message (one of the integer fields),
- but the value of the last integer is not as sent. The message is
- organised as
-
- struct mesg {
- int mesg_size;
- char mesg_body[MAXMESG];
- int mesg_sequence;
- };
-
- I am using two Sparc1 workstations, and don't use any byte ordering
- routine. Could someone tell me if the situation I have is something
- normal with the UDP implementation?
-
- Thanks in advance
-
- Yi Qin
- qinyi@cs.man.ac.uk
-