Great news for those suffering from Visual Studio 2010 IDE crashes with losing recent source code changes. Visual Studio 2012 is way more stable (event with Visual Studio 2010 Platform Toolset!) and suffers from crashes without losing editor changes. The worst thing you seem to be getting is: Which is an access violation or stack [...]
Posts Tagged ‘C++’
Crashes in Visual C++ 2012 vs. Visual C++ 2010
Posted: 30th September 2012 by Roman in TechnologyTags: access violation, C++, crash, IDE, microsoft, source code, visual studio
Continuous realloc()
Posted: 29th September 2012 by Roman in Source, UncategorizedTags: C++, CRT, heap, memory, Source, Windows API
A colleague raised a question that realloc does better than free + malloc because allocated memory block is never being actually shrunk and reallocations to smaller size following by reallocations to larger (but still not larger than one of the previous) do not lead to heap locks and actual underlying heap memory block reallocations. While [...]
Three ways to implement VBScript (VB6, VBA) callback from C++/ATL class
Posted: 11th August 2012 by Roman in ATL, SourceTags: ATL, automation, C++, COM, scripting, vb, vba, vbs
Suppose you have an automation object that needs to implement a callback into caller Visual Basic environment, which can be Scripting Host, Visual Basic for Applications, ASP etc. With all the late binding in VB scripting and so much different C++ code – how to put everything together? There are great choices, let us have [...]
Double right angle bracket kills Visual C++ source code outlining in IDE versions 2008, 2010, 2012
Posted: 11th August 2012 by Roman in SourceTags: amusing, C++, IDE, Source, visual studio
An amusing bug which seems to be affecting three of the versions of Visual Studio in a row: 2012, 2010, 2008: a double right angle bracket closing (or just present) the declaration of templated base class is breaking Visual Studio outlining capability (code scout? Intellisense? whatever). Have a space there and you are fine.
Enumerating Binary Resource Languages
Posted: 1st May 2012 by Roman in ATL, Source, UtilitiesTags: .rc, .res, C++, language, resource, utility, Windows API
The small application is a goos sample and useful tool in the same time. It enumerates PE binary resources and counts languages used. Why? Normally you want single language of resources, however Visual Studio IDE does not show you languages in a convenient way and it is so easy to make a language mess which [...]
LogProcessExceptions: Log Service Process Exceptions
Posted: 29th April 2012 by Roman in ATL, Seriously, Utilities, WTLTags: .DMP, ATL, C++, debug, debugger, exception, minidump, service, support, troubleshooting, utility
One of the nasty issues with LogProcessExceptions utility was that it was unable to attach to service processes and track them to catch their exceptions. The actual problem was that the processes were not listed in first place, so there was nothing to attach to. Access and security requirements necessary for a process to debug [...]
Enabling ATLTRACE output in Release configuration builds
Posted: 1st April 2012 by Roman in ATL, SourceTags: ATL, C++, debug, OutputDebugString, release
The original intent is pretty clear, as MSDN states: In release builds, ATLTRACE2 compiles to (void) 0. As simple as this, but once in a while you are in a situation where release build fails to work for unknown reason and you need additional information for troubleshooting, and then you remember that you had debug [...]
