Tips for debugging COM AddRef/Release leaks

In Windows environment, adding an accessibility support to a program means you'll have to do a lot of COM coding. For example, IRawElementProviderSimple is the most fundamental interface you should implement for every provider. So at first I started developing providers with ATL and throughout the process I learned few tips I'd like to share here: 1. Add the '_ATL_DEBUG_INTERFACES' … Continue reading Tips for debugging COM AddRef/Release leaks

Mongodb can’t accept a unicode configuration

I followed the official Mongodb configuration guide as described here, http://docs.mongodb.org/manual/tutorial/install-mongodb-on-windows/ Optional. Create a specific directory for MongoDB log files: md C:\mongodb\log Optional. Create a configuration file for the logpath option for MongoDB in the Command Promptby issuing this command: echo logpath=C:\mongodb\log\mongo.log > C:\mongodb\mongod.cfg However, the mongod kept failing from a Powershell environment. error command line: unrecognized line in ' ■l' … Continue reading Mongodb can’t accept a unicode configuration

Assigning NULL to std::function issue from VS2010/VS2013

Yesterday I tried to migrate a Visual Studio 2010 C++ project to Visual Studio 2013. But it instantly shows a compile error pointing xrefwrap header which wasn't clear at first. Here is the output: 4>C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\include\xrefwrap(283): error C2064: term does not evaluate to a function taking 2 arguments 4> C:\Program Files (x86)\Microsoft … Continue reading Assigning NULL to std::function issue from VS2010/VS2013

HTML5 Games: Creating Fun with HTML5, CSS3, and WebGL typo

I recently started reading a book titled "HTML5 Games: Creating Fun with HTML5, CSS3, and WebGL"  and it's good so far. But I found a small typo at the beginning so share it here: Listing 2.8 The Initial Game Module function showScreen(screenId) { var activeScreen = $("#game .screen.active")[0], screen = $("#" + screenId)[0]; if (activeScreen) … Continue reading HTML5 Games: Creating Fun with HTML5, CSS3, and WebGL typo