hang in printf on Windows

Viewed 357

So here is my minimal sample:

int main( int argc, char* argv[] )
{
  printf("First stuff\n");
}

My program hangs on the printf. I've dug into the disassembly through the debugger. Execution enters printf, makes its way into call qword ptr [__imp___stdio_common_vfprintf (07FF67A6D73F0h)]

From here, the jumps/calls are unnamed. The code is hung on a call to an explicit address. Is this anything that someone's seen before? I'm using MSVC tools v142, VS 2019, SDK 10.0.18362.0

My program was running fine, and suddenly started hanging on printfs. I thought I'd introduced some sort of memory corruption, until I moved the printf to the first line of my program and saw the same result. Deleting my output folder and recompiling has no effect. Though it does seem like some code changes can get me out of this odd mode, it will start happening again randomly.

Also, closing Visual Studio and reopening, then rebuilding, seems to resolve the issue.

0 Answers
Related