TSendData = procedure (Sender: TObject; BytesSent: Integer) of object;\r
\r
tlcomponent = class(tcomponent)\r
- private
- procedure releasetaskhandler(wparam,lparam:longint);
+ private\r
+ procedure releasetaskhandler(wparam,lparam:longint);\r
public\r
procedure release; virtual;\r
destructor destroy; override;\r
inherited destroy;\r
end;\r
\r
-procedure tlcomponent.releasetaskhandler(wparam,lparam:longint);
-begin
- free;
-end;
+procedure tlcomponent.releasetaskhandler(wparam,lparam:longint);\r
+begin\r
+ free;\r
+end;\r
\r
\r
procedure tlcomponent.release;\r
begin\r
- addtask(releasetaskhandler,self,0,0);
+ addtask(releasetaskhandler,self,0,0);\r
end;\r
\r
procedure tlasio.release;\r
// fdstestr : fdset;\r
// fdstestw : fdset;\r
begin\r
- if state <> wsconnected then exit;\r
+ if state <> wsconnected then begin\r
+ result := -1;\r
+ exit;\r
+ end;\r
\r
lensent := sendq.get(data,packetbasesize*2);\r
if assigned(data) then result := myfdwrite(fdhandleout,data^,lensent) else result := 0;\r