Updates:
        Cc: w...@chromium.org

Comment #14 on issue 1112 by w...@chromium.org: Exe's downloads fail with  
FTP.
http://code.google.com/p/chromium/issues/detail?id=1112

The FTP code in the old and new HTTP stacks is mostly the
same.  The new HTTP stack will have its own portable FTP
implementation, but right now it uses the system library
(WinInet on Windows) for FTP.

When I visit
ftp://download.sony.com/US/voicerecorder/PLAYERPLUGINSETUP129.EXE
with my trunk developer build, I hit this code in

   } else if (state_ == FINDING_FIRST_FILE) {
     if (result.dwError != ERROR_SUCCESS) {
       DWORD result_error = result.dwError;
       CleanupConnection();
       // Fixup the error message from our directory/file guessing.
       if (!is_directory_ && result_error == ERROR_NO_MORE_FILES)
         result_error = ERROR_PATH_NOT_FOUND;  <=== HIT HERE
       NotifyStartError(URLRequestStatus(URLRequestStatus::FAILED,
                        WinInetUtil::OSErrorToNetError(result_error)));
       return;
     }
     request_handle_ = (HINTERNET)result.dwResult;
     OnFindFirstFile(result.dwError);
   } else if (state_ == GETTING_DIRECTORY) {

with this call stack:

>       chrome.dll!URLRequestFtpJob::OnIOComplete(const
URLRequestInetJob::AsyncResult & result={...})  Line 232        C++
        chrome.dll!URLRequestInetJob::CallOnIOComplete(const
URLRequestInetJob::AsyncResult & result={...})  Line 227 + 0x13 bytes   C++
        chrome.dll!DispatchToMethod<URLRequestInetJob,void (__thiscall
URLRequestInetJob::*)(URLRequestInetJob::AsyncResult const
&),URLRequestInetJob::AsyncResult>(URLRequestInetJob * obj=0x04fdcb68, void  
(const
URLRequestInetJob::AsyncResult &)* method=0x01adeb50, const
Tuple1<URLRequestInetJob::AsyncResult> & arg={...})  Line 393 + 0xf bytes       
 
C++
        chrome.dll!RunnableMethod<URLRequestInetJob,void (__thiscall
URLRequestInetJob::*)(URLRequestInetJob::AsyncResult const
&),Tuple1<URLRequestInetJob::AsyncResult> >::Run()  Line 312 + 0x1e bytes       
 
C++
        chrome.dll!MessageLoop::RunTask(Task * task=0x05c31a48)  Line 308 + 0xf 
 
bytes   
C++
        chrome.dll!MessageLoop::DeferOrRunPendingTask(const  
MessageLoop::PendingTask
& pending_task={...})  Line 319 C++
        chrome.dll!MessageLoop::DoWork()  Line 408 + 0xc bytes  C++
        chrome.dll!base::MessagePumpForIO::DoRunLoop()  Line 445 + 0x19 bytes   
C++
        
chrome.dll!base::MessagePumpWin::RunWithDispatcher(base::MessagePump::Delegate  
*
delegate=0x0541feb4, base::MessagePumpWin::Dispatcher *  
dispatcher=0x00000000)  Line
52 + 0xf bytes  C++
        chrome.dll!base::MessagePumpWin::Run(base::MessagePump::Delegate *
delegate=0x0541feb4)  Line 78 + 0x1c bytes      C++
        chrome.dll!MessageLoop::RunInternal()  Line 197 + 0x2a bytes    C++
        chrome.dll!MessageLoop::RunHandler()  Line 181  C++
        chrome.dll!MessageLoop::Run()  Line 155 C++
        chrome.dll!base::Thread::ThreadMain()  Line 156 C++
        chrome.dll!`anonymous namespace'::ThreadFunc(void * closure=0x04f77000) 
  
Line
26 + 0xf bytes  C++
        kernel32.dll!_basethreadst...@8()  + 0x37 bytes 

This means our FtpFindFirstFileA call in
URLRequestFtpJob::OnSetCurrentDirectory fails asynchronously
with the ERROR_NO_MORE_FILES error.

As an experiment, I changed the test
     if (result.dwError != ERROR_SUCCESS) {
to
     if (is_directory_ && result.dwError != ERROR_SUCCESS) {
to force the subsequent statement
     OnFindFirstFile(result.dwError);
to be executed.  This allows me to download the file.

--
You received this message because you are listed in the owner
or CC fields of this issue, or because you starred this issue.
You may adjust your issue notification preferences at:
http://code.google.com/hosting/settings

--~--~---------~--~----~------------~-------~--~----~
Automated mail from issue updates at http://crbug.com/
Subscription options: http://groups.google.com/group/chromium-bugs
-~----------~----~----~----~------~----~------~--~---

Reply via email to