Module already had StgCreateDocfileOnILockBytes. This patch adds StgOpenStorageOnILockBytes function as well for files already created and in memory.
Updated patch resolves a memory leak due to a missing Release()
I think both pStgPriority and plb must be released. Also, you should make sure the error path (when pStgPriority fails) should release plb.
Updated with missing Release() in error condition.