Hey everyone, this one's got me baffled. I had a bit of code that I kept on using over and over in the same program, so I figured it would be simpler and easier just to make it a function:
For some reason, when I replaced the exact same lines of code with a call to the function, I would always get a stack overflow. Then I made the function inline, and it worked fine again. Is there any quick and obvious reason that I'm not seeing, or is it something very code-specific?Code:void backToConnect(HWND dialogToEnd); { server->release(); delete server; server = new Socket; dlgState = DS_CONNECT; EndDialog(dialogToEnd, 0); }
**EDIT**
Hmm, never mind... now, it doesn't work with the inline either. Still, any ideas? I thought the code should function in the same way since server and dlgState are global variables, but apparently it doesn't...



LinkBack URL
About LinkBacks


