00048                    :
00049 
00050     This function moves an LPC message block and optionally sets 
the message
00051     
type and client 
id to 
the specified values.
00052 
00053 Arguments:
00054 
00055     DstMsg     - Supplies a pointer to 
the destination message.
00056 
00057     SrcMsg     - Supplies a pointer to 
the source message.
00058 
00059     SrcMsgData - Supplies a pointer to 
the source message data to
00060                  copy to destination.
00061 
00062     MsgType    - If non-zero, then store in 
type field of 
the
00063                  destination message.
00064 
00065     ClientId   - If non-
NULL, then points to a ClientId to copy to
00066                  
the destination message.
00067 
00068 Return Value:
00069 
00070     None
00071 
00072 --*/
00073 
00074 {
00075     ULONG NumberDwords;
00076     ULONGLONG Temp1, Temp2, Temp3;
00077 
00078     
00079     
00080     
00081 
00082     *((PULONG)DstMsg)++ = NumberDwords = *((PULONG)SrcMsg)++;
00083     NumberDwords = ((0x0000FFFF & NumberDwords) + 3) >> 2;
00084 
00085     
00086     
00087     
00088 
00089     *((PULONG)DstMsg)++ = MsgType == 0 ? *((PULONG)SrcMsg)++ :
00090                          *((PULONG)SrcMsg)++ & 0xFFFF0000 | MsgType & 0xFFFF;
00091 
00092     
00093     
00094     
00095 
00096     *((PULONG_PTR)DstMsg)++ = ClientId == 
NULL ? *((PULONG_PTR)SrcMsg) :
00097             *((PULONG_PTR)ClientId)++;
00098     ((PULONG_PTR)SrcMsg)++;
00099 
00100     *((PULONG_PTR)DstMsg)++ = ClientId == 
NULL ? *((PULONG_PTR)SrcMsg) :
00101             *((PULONG_PTR)ClientId);
00102     ((PULONG_PTR)SrcMsg)++;
00103 
00104     
00105     
00106     
00107 
00108     *((PULONG_PTR)DstMsg)++ = *((PULONG_PTR)SrcMsg)++;
00109     *((PULONG_PTR)DstMsg)++ = *((PULONG_PTR)SrcMsg)++;
00110 
00111     
00112     
00113     
00114 
00115     
if (NumberDwords > 0) {
00116 
00117         
if ((ULONG_PTR) SrcMsgData & (
sizeof(ULONGLONG)-1)) {
00118 
00119             
00120             
00121             
00122 
00123             Temp1 = *((PULONG) SrcMsgData)++;
00124 
00125             
while (NumberDwords >= 3) {
00126 
00127                 Temp2 = *((PULONGLONG)SrcMsgData)++;
00128                 *((PULONGLONG)DstMsg)++ = (Temp2 << 32) | Temp1;
00129                 Temp1 = Temp2 & 0x0000FFFF;
00130                 NumberDwords -= 
sizeof(ULONGLONG) / 
sizeof(ULONG);
00131             }
00132 
00133             *(PULONG)DstMsg = (ULONG)Temp1;
00134             NumberDwords--;
00135 
00136         } 
else {
00137 
00138             
00139             
00140             
00141             
00142 
00143             
while (NumberDwords >= 
sizeof(ULONGLONG) / 
sizeof(ULONG)) {
00144 
00145                 *((PULONGLONG)DstMsg)++ = *((PULONGLONG)SrcMsgData)++;
00146                 NumberDwords -= 
sizeof(ULONGLONG) / 
sizeof(ULONG);
00147             }
00148         }
00149 
00150         
00151         
00152         
00153     
00154         
while (NumberDwords--) {
00155             *((PULONG)DstMsg)++ = *((PULONG)SrcMsgData)++;
00156         }
00157     }
00158 }