ASACORE-963 Cleanup AJ globals.

AJ 14.06 uses a number of global pointers (including singletons) that may
point to objects on the process heap. The issue is that the lifetime of these
objects in the heap may be longer than AJ code itself, thus we need to
provide a way to cleanup these global pointers before AJ is unloaded.

Here is the list as reported by Microsoft App Verifier tool:

1. [common\src\string.cc] line 56 - global pointer to an object on the heap
const String* emptyString = new String();

2. [common\src\logger.cc] line 98 - singleton
LoggerSetting* LoggerSetting::singleton

3. [common\os\windows\environ.cc] line 46 - singleton
static Environ* env

4. [common\crypto\cng\cryptoaes.cc] line 48-49 - global BCRYPT handles
static BCRYPT_ALG_HANDLE ecbHandle = 0;
static BCRYPT_ALG_HANDLE ccmHandle = 0;

5. [common\crypto\cng\cryptorsa.cc] line 47 - global BCRYPT handle
static BCRYPT_ALG_HANDLE rsaHandle = 0;

6. [common\crypto\cng\cryptohash.cc] line 42 - global BCRYPT handles
static BCRYPT_ALG_HANDLE algHandles[3][2] = { 0 };

We need to implement functions to clean these globals before unload or
else they could leak resources.

An AJ client that wishes to cleanly unload can call these new Cleanup
functions like so:

...
qcc::cngCache.Cleanup();
qcc::LoggerSetting::Cleanup();
qcc::Environ::Cleanup();

Change-Id: I9e9a1fb4546b115fa41e9285eb2b48896f6e43ce
Signed-off-by: Way Vadhanasin <wayvad@microsoft.com>
Merge "ASACORE-963 Cleanup AJ globals."