Skip to content

Commit 351cea5

Browse files
Make sure cdm_path exists
1 parent d0c56c3 commit 351cea5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/inputstreamhelper.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
import xbmc
1111
import xbmcaddon
1212
import xbmcgui
13+
import xbmcvfs
1314

1415

1516
class InputStreamHelper(object):
@@ -23,11 +24,15 @@ def __init__(self, protocol, drm=None):
2324

2425
self.protocol = protocol
2526
self.drm = drm
27+
2628
if self.protocol not in config.INPUTSTREAM_PROTOCOLS:
2729
raise self.InputStreamException('UnsupportedProtocol')
2830
else:
2931
self._inputstream_addon = config.INPUTSTREAM_PROTOCOLS[self.protocol]
32+
3033
if self.drm:
34+
if not xbmcvfs.exists(self._cdm_path()):
35+
xbmcvfs.mkdir(self._cdm_path())
3136
if self.drm not in config.DRM_SCHEMES:
3237
raise self.InputStreamException('UnsupportedDRMScheme')
3338
else:

0 commit comments

Comments
 (0)