Out of stack space error in VB when uploading file - WeOnlyDo Discussion board

Out of stack space error in VB when uploading file (wodSFTP / wodSFTP.NET / wodSFTPdll)

by RBosveld, Wednesday, October 20, 2004, 17:27 (7340 days ago)

Hi,
We've recently purchased wodftpdlx and I'm very pleased with it so far. However I've run into a strange problem and no matter what I try, I can't get around it. I'm working in Visual Basic btw.
Whenever I try to upload a file larger then roughly 32kb with SFTP it freezes for a few secs then VB pops up a messagebox with an Out of stack space error. It works fine for smaller files. When I use regular FTP it works fine for any filesize.

To exclude that it might be caused by my own code, I tried the same with one of your samples (VB/Component/1. Simple). I still get a stack error, only slightly different this time: VB just quits alltogether and DrWatson pops up. When I look in the DrWatson log I see this message:

[code]Application exception occurred:
App: VB6.exe (pid=1840)
When: 10/20/2004 @ 15:37:11.571
Exception number: c00000fd (stack overflow)
[/code]

To exclude everything (like things going wrong in the code in the events, etc), I created a new empty project and only put in the most basic statements to connect and upload. Now I get the messagebox with the Out of stack space error again.

Here's that project:
Create a form, put a button on it, then copy & paste the following code:

[code]
Option Explicit

Dim WithEvents Ftp1 As wodFtpDLXCom

Private Sub Form_Load()

Set Ftp1 = New wodFtpDLXCom
End Sub

Private Sub Form_Unload(Cancel As Integer)

Set Ftp1 = Nothing
End Sub

Private Sub Command1_Click()

Ftp1.HostName = <edited: our server>
Ftp1.Login = <edited: my username>
Ftp1.Password = <edited: my password>
Ftp1.Passive = False
Ftp1.Protocol = SFTP
Ftp1.Blocking = True

Ftp1.Connect

Ftp1.RemotePath = /home/rbo003db/test
Ftp1.LocalPath = D:\Test34kb.txt

Ftp1.PutFile '<- heres where the error occurs

Ftp1.Disconnect
End Sub
[/code]

I also created an .exe and tried running that to see what happens. When I press the button the program freezes for a few secs then simply disappears without any errormsg.


The software I am using:
- Visual Basic 6
- Windows 2000 SP4 + all the latest updates
- wodFTPdlx component, version 2.3.0.5
- The FTP Server is on our intranet. This is what it reports when I connect to it: Version 6.5/OpenBSD, linux port 0.3.2


The problem only occurs when I use SFTP. Unfortunately, we really need SFTP.:)
I hope you can help me with this problem.

Thx,

Ronald Bosveld
ING Car Lease Netherlands


Complete thread: