FTP.PUT invalid pointer error

Giganews Newsgroups
Subject: FTP.PUT invalid pointer error
Posted by:  Tim (tim.f…@orcus.co.uk)
Date: Wed, 13 Jun 2007

Hi All

I wonder if someone could help.

I've got a very simple application that tries to connect and upload a file.

Code as follows

//ftp connection is successfull

while (res = false) and (retry < 3) do
        begin
          try
            begin
              dftp.Put(upload_file,dest_file,false);
              res := true;
            end
          except
            on e:exception do
              inc(retry);
          end;
        end;

Occasionally the put command generates an invalid pointer exception which is
only visiable while in debug mode and seems to work the second time it goes
through the loop.

Does anyone know why this error occurs and what I can do to prevent it?

Many thanks

Tim

Replies