Esempio n. 1
0
        // 填充报文的头部, 返回报文的总长度
        public int FillReq(byte[] sendData, int flag, string strReq)
        {
            CSynFiles.ApendByte(sendData, 4, flag);      // 填充flag 标记
            int extLen = CSynFiles.ApendByte(sendData, 12, strReq);

            CSynFiles.ApendByte(sendData, 8, extLen);
            CSynFiles.ApendByte(sendData, 0, extLen + 12);
            return(extLen + 12);
        }