19

I try to run diagnostic tools in Visual Studio 2015 Community for a test project.

My code:

#include<iostream>

int main()
{
  for (;;)
  {
    std::cout << "Hello, World!";
    getchar();
  }
  return 0;
}

I use x64 platform in configuration Debug. The Window Diagnostic Tools fail unexpectedly, saying the following:

The diagnostic tools failed unexpectedly. The Diagnostic Hub output in the Output window may contain additional information.

Image1

Diagnostic Hub:

The scratch directory cannot have a trailing junction point.

What does it mean? How do I correct this error?

Image2

1
  • 2
    Upvoting because I can find no reference to this on Google at all (aside from this question and a terrible nasty fraudulent scraper git) Aug 27, 2015 at 11:34

2 Answers 2

5

It's complaining that the "scratch directory" isn't actually a directory but some kind of reparse point. Reparse points are used to implement various NTFS file system features, notably junction points and symbolic links.

I'm not sure which directory the scratch directory is supposed to be, but my guess is that it's your TEMP directory (normally something like C:\Users\ROSSRI~1\AppData\Local\Temp) and you've done something like moved it to another drive using a junction point or symbolic link. You can check to see if your TEMP directory isn't really a directory by entering the following command in the Windows command prompt:

for /d %i in ("%TEMP%") do @echo %~ai

If it prints d-------- then it's a normal directory, but if it prints d-------l then it's a junction point.

Assuming I'm correct the solution would be either to move the TEMP directory back or point the TEMP and TMP environment variables to the location where you moved it.

1

Just :) restart your computer (yes nothing else helped me).

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.