Board index » delphi » Attn Indy Prob with TidFTP

Attn Indy Prob with TidFTP

I am trying to automate a download process where I change directories, get
contents and download files when sourcefile <> destination file. I find that
the idFTP component get lost in a loop quite often after a call to
TidFTP.List call. Traced problem to idSimpleServer on line "While
(FAbortedRequested = false) and (result = false) do begin" (Code below)
This loop continues until program is terminated. Program cant be shut down,
I assume because of idAntiFreeze.

Another problem I havent figured out yet is sometimes a call to
TidFTP.Get(const ASourceFile, ADestFile: string; const ACanOverwrite:
boolean = false) will also go off into loopyville. The destination file gets
created with zero bytes but then thats the end of it. Nothing else happens
after that

function TIdSimpleServer.Listen: boolean;
begin
  //TODO: Add a timeout to this function.
  result := false;
  if not FListening then begin
    BeginListen;
  end;
  with Binding do begin
    while (FAbortedRequested = false) and (result = false) do begin
      result := Readable(AcceptWait);
    end;
    if result then begin
      Accept(Handle);
    end;
    GStack.WSCloseSocket(ListenHandle);
    FListenHandle := Id_INVALID_SOCKET;
  end;
end;

 

Re:Attn Indy Prob with TidFTP


Quote
"Dale Wolver" <dwolverNOSPAMhome.com> wrote in message

news:3d092065$1_2@dnews...

Quote
> Traced problem to idSimpleServer on line "While
> (FAbortedRequested = false) and (result = false) do begin" (Code below)

Dale:

The code you listed does not match the current source from Indy 9.0.3B on
the FTP server.  What Indy version are you using?

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.370 / Virus Database: 205 - Release Date: 6/5/2002

Other Threads