![]() |
SendParameter() |
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Public Function |
Declared in: ICMPSocket.h |
BOOL SendParameter( LPCSTR lpDestinationAddress, unsigned char cError);
try { LPICMPHeader lpHead; lpHead=ConstructICMP(); if (!lpHead) { ReportError("SendParameter","Failed to construct ICMP header!"); return FALSE; } lpHead->ICMPType=ICMP_Parameter; lpHead->ICMPCode=ICMP_Parameter_ERROR; lpHead->sICMP.sUC.uc1=cError; //And the checksum lpHead->ICMPChecksum=CalculateChecksum((unsigned short*)lpHead,ICMPHeaderLength); //Send it BOOL bSend; bSend=SendICMP(lpHead,lpDestinationAddress); //Clear up delete lpHead; return bSend; } ERROR_HANDLER_RETURN("SendParameter",FALSE)
![]() |
Site content copyright © 2001 Barak Weichselbaum. See the About page for additional notices. This page last updated: 27 Jun 2001. |