One problem about the code in IMSamp's recv.c CLReceiveIndication

I read the IMSamp for NTV4.0 written by Jim. Some codes in it confuse me.

Here is the code fragement in CLReceiveIndication:


PSINGLE_LIST_ENTRY LookaheadEntry;

PNDIS_BUFFER LookaheadNdisBuffer;

LookaheadNdisBuffer=((PIM_BUFFER_CONTEXT)LookaheadEntry)->NdisBuffer;

//Here is the code made me confused.

NdisMoveMemory(LookaheadEntry,HeaderBuffer,HeaderBufferSize);

^^^^^^^^^^^


Why use LookaheadEntry here instead of LookaheadNdisBuffer?


DVD´óƬ£¬Ò»ÂÉ10Ôª http://shopping.263.net/category02.htm
ÃÀÈÝÑøÑÕ¡¢¼õ·ÊÊÝÉíÃؾ÷ http://shopping.263.net/category10.htm


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com

It looks like you need a little help understanding what a NDIS buffer
descriptor is. It is NOT an array of bytes that you copy data into. It is
an opaque data structure that is used by NDIS for memory management and
other purposes.

Hopefully the discussion at the following URL will help you:

http://www.pcausa.com/resources/ndispacket.htm

The newer DDK documentation is also helpful. Search for NDIS_BUFFER and read
every item that the search returns.

Finally, the newer Windows 2000 and Windows XP DDK NDIS IM samples are much
better then the work that Jim did a long time ago.

Good luck,

Thomas F. Divine

PCAUSA - Toolkits & Resources For Network Software Developers
NDIS Protocol - NDIS Intermediate - TDI Client
http: - http:

----- Original Message -----
From: “Ҷ??”
To: “NT Developers Interest List”
Sent: Thursday, August 02, 2001 9:53 PM
Subject: [ntdev] One problem about the code in IMSamp’s recv.c
CLReceiveIndication

> I read the IMSamp for NTV4.0 written by Jim. Some codes in it confuse me.
>
> Here is the code fragement in CLReceiveIndication:
>
>
>
> -------------------------------------------------------
>
> PSINGLE_LIST_ENTRY LookaheadEntry;
>
> PNDIS_BUFFER LookaheadNdisBuffer;
>
>
>
> …
>
>
>
> LookaheadNdisBuffer=((PIM_BUFFER_CONTEXT)LookaheadEntry)->NdisBuffer;
>
>
>
> …
>
> //Here is the code made me confused.
>
> NdisMoveMemory(LookaheadEntry,HeaderBuffer,HeaderBufferSize);
>
> ^^^^^^^^^^^
>
> ---------------------------------------------------
>
> Why use LookaheadEntry here instead of LookaheadNdisBuffer?
>


You are currently subscribed to ntdev as: $subst(‘Recip.EmailAddr’)
To unsubscribe send a blank email to leave-ntdev-$subst(‘Recip.MemberIDChar’)@lists.osr.com</http:></http:>