Post a reply

Before posting, please read how to report bug or request support effectively.

Bug reports without an attached log file are usually useless.

Options
Add an Attachment

If you do not want to add an Attachment to your Post, please leave the Fields blank.

(maximum 10 MB; please compress large files; only common media, archive, text and programming file formats are allowed)

Options

Topic review

martin

Re: NRE with SynchronizeDirectories()

This issue has been added to the tracker:
https://winscp.net/tracker/1683

Please, set Session.Timeout to a longer value to avoid the problem.
vslee

Okay, got both files.
martin

Re: Log files

You cannot use .xml extension for a session log. Please using anything else, like .log.
vslee

Log files

I set those two properties. Unfortunately it only created a debug log and not a session log. I have attached the debug log. Does that help?
martin

Re: NRE with SynchronizeDirectories()

Please set Session.DebugLogPath and Session.SessionLogPath and submit both logs.

Submit the log with your post as an attachment. You may want to remove data you consider sensitive. If you do not want to post the log publicly, you can mark the attachment as private.
vslee

Here is some more info:
It is throwing in Session.cs because _process is null.
Here is the call stack:
> WinSCPnet.dll!WinSCP.Session.CheckForTimeout(string additional) Line 1753 C#
WinSCPnet.dll!WinSCP.PatientFileStream.Wait(ref int interval) Line 51 C#
WinSCPnet.dll!WinSCP.PatientFileStream.Read(byte[] array, int offset, int count) Line 36 C#
System.Xml.dll!System.Xml.XmlTextReaderImpl.ReadData() Unknown
System.Xml.dll!System.Xml.XmlTextReaderImpl.ParseElementContent() Unknown
System.Xml.dll!System.Xml.XmlTextReaderImpl.Read() Unknown
WinSCPnet.dll!WinSCP.SessionLogReader.DoRead() Line 96 C#
WinSCPnet.dll!WinSCP.SessionLogReader.Read(WinSCP.LogReadFlags flags) Line 53 C#
WinSCPnet.dll!WinSCP.ElementLogReader.Read(WinSCP.LogReadFlags flags) Line 53 C#
WinSCPnet.dll!WinSCP.SessionElementLogReader.Read(WinSCP.LogReadFlags flags) Line 23 C#
WinSCPnet.dll!WinSCP.ElementLogReader.ReadToEnd(WinSCP.LogReadFlags flags) Line 73 C#
WinSCPnet.dll!WinSCP.ElementLogReader.Dispose() Line 32 C#
WinSCPnet.dll!WinSCP.SessionElementLogReader.Dispose() Line 17 C#
WinSCPnet.dll!WinSCP.Session.Cleanup() Line 1321 C#
WinSCPnet.dll!WinSCP.Session.Dispose() Line 185 C#
ReceiverCompressor.exe!ReceiverCompressor.MainWindow.downloadFiles() Line 284 C#
mscorlib.dll!System.Threading.ThreadHelper.ThreadStart_Context(object state) Unknown
mscorlib.dll!System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx) Unknown
mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state, bool preserveSyncCtx) Unknown
mscorlib.dll!System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext executionContext, System.Threading.ContextCallback callback, object state) Unknown
mscorlib.dll!System.Threading.ThreadHelper.ThreadStart() Unknown
vslee

NRE with SynchronizeDirectories()

I am able to get WinSCP to throw a NRE internally by doing a SynchronizeDirectories() Sftp from a remote directory containing 90k files to a local directory containing 30k files. I can assist by running a debug version or provide you with log files if you wish.