Quantcast
Channel: Xojo Programming Forum - Latest topics
Viewing all articles
Browse latest Browse all 4300

FolderItem.TrueItemsMBS and preemptive thread don't play well together

$
0
0

Hi,

I’ve found that calling FolderItem.TrueItemsMBS in a preemptive thread can produce weird behaviours concerning debugging.

In my case, I’m using TrueItemsMBS for a folder on a remote server. That folder has a lot of items inside it.
After TrueItemsMBS has been called, breakpoints are ignored, stepping won’t work and pausing is also odd (e.g. the thread won’t appear in the list).

Another attempt: putting a breakpoint right at the TrueItemsMBS line, the debugger correctly breaks, then I use “Step over” and either of these happens:
1: if the call returns immediately (few files or fast file system), debugging stays reliable and the next line is executed.
2: if the call takes more than a few seconds, the IDE goes to the “no code view” and the weird behaviours described above apply.

At this stage, I don’t know whether this behaviour is specific to the TrueItemsMBS/TrueFilesMBS/TrueFoldersMBS calls or if any method which takes time in the framework would cause this too. If the former, I’d ask Christian to take a look at these functions (are they perhaps not thread-safe?); if the latter, it’d call it a bug in the framework and fill a bug report.
I currently have no idea to test quickly using other functions, so I thought discussing about it could be a good idea.

2 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 4300

Latest Images

Trending Articles



Latest Images