Browse by Tags
All Tags »
Gotcha »
C++ (RSS)
Recently while making a bug fix to our selection tracking code I discovered an unexpected behavior with CComPtr<T> instances. The crux of the fix included creating a new tracking mechanism exposed via COM in the type ISelectionTracking.
Read More...
Spent about an hour debugging a bit of code today. I was attempting to read data from a particular source and kept getting back failure codes. After some debugging I discovered the data didn't actually exist in the source I was reading from.
Read More...
Recently I got bit by void* again because of another C++ quirk I didn't think through. I had a class which wrapped a void* which could be one of many different structs. The structs were POD and didn't have any shared functionality hence I
Read More...
While investigating a crash during a suite run I found the stack walk included the destructor for a CComAutoCriticalSection . This is a fairly reliable class so I immediately suspected my code. I did a couple of quick checks for a double free and didn't
Read More...
Today what started out as a crash due to a pure virtual call turned into finding a gotcha in CComPtrBase<T>. Essentially the code in question boiled down to the following. Can you spot the problem? void GetAStudent(CComPtrBase<T> &spStudent)
Read More...