Skip to content

Race condition resulting in unhandled exception and VS crash #1

Description

@martinky

In large solutions (thousands of indexed files) where the indexing takes quite long, the user may do this:

  1. Invoke the plugin window, type a few letters,
  2. close the window,
  3. Invoke the window again, type more letters
  4. --> crash

This is what happens internally:

  1. On the first invoke a full index of the solution is started in a background thread. This indexing takes long enough time that it still runs when the plugin window is invoked again.
  2. On the second invoke, another parallel index is started (the first one still runs).
  3. When the first index finishes, it starts a search over the indexed data.
  4. While the search executes, the second index finishes and rewrites the index collection on which the search query currently executes, resulting in a race condition.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions