Use read-only access for enumerating classes to prevent access denied bugs
Com might already initialized, it's not a problem see http://msdn.microsoft.com/en-ca/library/windows/desktop/ms695279(v=vs.85).aspx
Merge remote-tracking branch 'upstream/master'
Merge pull request #373 from lwahonen/master

Small COM fixes