Mail Archives: djgpp/1997/03/05/03:49:06
On 4 Mar 1997, nikki wrote:
> if (callback_regs.x.cx>16384L) {
> callback_regs.x.es=0;
> callback_regs.x.di=0; // frame is >16k! too long so discard
Why are you limiting the size of the buffer to 16K? You can allocate
much more than that and not limit it at all.
> while (retries--) {
> regs.x.ax=0x400;
> regs.x.ds=pktout.rm_segment;
> regs.x.es=pktout.rm_segment; // buggy drivers need es:
> regs.x.si=0;
> regs.x.cx=length;
> _go32_dpmi_simulate_int(pktdrv.irq,®s);
The above is most likely the culprit: you don't zero out regs.x.ss,
regs.x.sp and regs.x.flags before calling `_go32_dpmi_simulate_int'. The
best way is just to call `__dpmi_int' instead, though.
> dosmemput(arpbuf,60,pktout.rm_segment*16);
> // !!! THE ABOVE LINE CAUSES THE PROBLEM !!!
> send_pkt(60);
I think `send_pkt' is causing the trouble, because of regs.x.ss etc.
> r.x.cx=typelen;
This doesn't seem to be defined anywhere. A typo?
- Raw text -