File tree Expand file tree Collapse file tree 1 file changed +15
-9
lines changed
Expand file tree Collapse file tree 1 file changed +15
-9
lines changed Original file line number Diff line number Diff line change @@ -98,21 +98,27 @@ void DrmManager::removeUniqueId(int uniqueId) {
9898}
9999
100100status_t DrmManager::loadPlugIns () {
101+
102+ String8 vendorPluginDirPath (" /vendor/lib/drm" );
103+ loadPlugIns (vendorPluginDirPath);
104+
101105 String8 pluginDirPath (" /system/lib/drm" );
102- return loadPlugIns (pluginDirPath);
106+ loadPlugIns (pluginDirPath);
107+ return DRM_NO_ERROR;
108+
103109}
104110
105111status_t DrmManager::loadPlugIns (const String8& plugInDirPath) {
106- if ( mSupportInfoToPlugInIdMap . isEmpty ()) {
107- mPlugInManager .loadPlugIns (plugInDirPath );
108- Vector<String8> plugInPathList = mPlugInManager . getPlugInIdList ();
109- for ( unsigned int i = 0 ; i < plugInPathList. size (); ++i) {
110- String8 plugInPath = plugInPathList[i] ;
111- DrmSupportInfo* info = mPlugInManager . getPlugIn (plugInPath). getSupportInfo ( 0 );
112- if (NULL != info ) {
112+ mPlugInManager . loadPlugIns (plugInDirPath);
113+ Vector<String8> plugInPathList = mPlugInManager .getPlugInIdList ( );
114+ for ( unsigned int i = 0 ; i < plugInPathList. size (); ++i) {
115+ String8 plugInPath = plugInPathList[i];
116+ DrmSupportInfo* info = mPlugInManager . getPlugIn (plugInPath). getSupportInfo ( 0 ) ;
117+ if ( NULL != info) {
118+ if (mSupportInfoToPlugInIdMap . indexOfKey (*info) < 0 ) {
113119 mSupportInfoToPlugInIdMap .add (*info, plugInPath);
114- delete info;
115120 }
121+ delete info;
116122 }
117123 }
118124 return DRM_NO_ERROR;
You can’t perform that action at this time.
0 commit comments