Author: remi
Date: 2008-12-11 07:54:33 +0100 (Thu, 11 Dec 2008)
New Revision: 3052
Modified:
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Unit1.pas
Log:
* code and comments cleaning
Modified:
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Unit1.pas
===================================================================
---
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Unit1.pas
2008-12-11 06:41:50 UTC (rev 3051)
+++
software_suite_v2/software/http_server_resources/chatter_tux/trunk/ChatterTux/Unit1.pas
2008-12-11 06:54:33 UTC (rev 3052)
@@ -220,37 +220,32 @@
end;
end;
- // Retrieve the local IP
- if LocalIPList.Count > 0 then
- begin
- // Configure the socket monitor
- isMonitored := false;
- MonitorSocket.onPacketEvent := PacketEvent;
- MonitorSocket.Addr := myIP;
- MonitorSocket.AddrMask := '255.255.255.0';
- MonitorSocket.IgnoreData := false;
- MonitorSocket.IgnoreLAN := true;
- MonitorSocket.ClearIgnoreIP;
+ // Configure the socket monitoring
+ isMonitored := false;
+ MonitorSocket.onPacketEvent := PacketEvent;
+ MonitorSocket.Addr := myIP;
+ MonitorSocket.AddrMask := '255.255.255.0';
+ MonitorSocket.IgnoreData := false;
+ MonitorSocket.IgnoreLAN := true;
+ MonitorSocket.ClearIgnoreIP;
- // Start the monitoring
+ // Attempts to start the monitoring
+ try
+ MonitorSocket.StartMonitor(true);
+ isMonitored := true;
+ except
try
- MonitorSocket.StartMonitor(true);
+ MonitorSocket.StartMonitor(false);
isMonitored := true;
except
- try
- MonitorSocket.StartMonitor(false);
- isMonitored := true;
- except
- // Can't monitoring your network card ...
- end;
+ // Can't monitoring the network card ...
end;
- if isMonitored then
- begin
- break;
- end;
- end else
+ end;
+
+ // The network card which is connected to internet is successfuly monitored
+ if isMonitored then
begin
- sleep(1000);
+ break;
end;
// Decrease the retry counter
------------------------------------------------------------------------------
SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada.
The future of the web can't happen without you. Join us at MIX09 to help
pave the way to the Next Web now. Learn more and register at
http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn