1e41f4b71Sopenharmony_ci# DRM Error Codes
2e41f4b71Sopenharmony_ci
3e41f4b71Sopenharmony_ci> **NOTE**
4e41f4b71Sopenharmony_ci>
5e41f4b71Sopenharmony_ci> This topic describes only module-specific error codes. For details about universal error codes, see [Universal Error Codes](../errorcode-universal.md).
6e41f4b71Sopenharmony_ci
7e41f4b71Sopenharmony_ci## 24700101 Unknown Error
8e41f4b71Sopenharmony_ci
9e41f4b71Sopenharmony_ci**Error Message**
10e41f4b71Sopenharmony_ci
11e41f4b71Sopenharmony_ciAll unknown errors.
12e41f4b71Sopenharmony_ci
13e41f4b71Sopenharmony_ci**Description**
14e41f4b71Sopenharmony_ci
15e41f4b71Sopenharmony_ciAn unknown error is returned when the API is called.
16e41f4b71Sopenharmony_ci
17e41f4b71Sopenharmony_ci**Possible Causes**
18e41f4b71Sopenharmony_ci
19e41f4b71Sopenharmony_ciThe plug-in returns an undefined or custom error.
20e41f4b71Sopenharmony_ci
21e41f4b71Sopenharmony_ci**Procedure**
22e41f4b71Sopenharmony_ci
23e41f4b71Sopenharmony_ciRefer to the plug-in document to rectify the fault.
24e41f4b71Sopenharmony_ci
25e41f4b71Sopenharmony_ci## 24700102 Memory Allocation Failure
26e41f4b71Sopenharmony_ci
27e41f4b71Sopenharmony_ci**Error Message**
28e41f4b71Sopenharmony_ci
29e41f4b71Sopenharmony_ciMemory allocation failure.
30e41f4b71Sopenharmony_ci
31e41f4b71Sopenharmony_ci**Description**
32e41f4b71Sopenharmony_ci
33e41f4b71Sopenharmony_ciThis error code is reported if a memory allocation failure or null pointer occurs when an API is called.
34e41f4b71Sopenharmony_ci
35e41f4b71Sopenharmony_ci**Possible Causes**
36e41f4b71Sopenharmony_ci
37e41f4b71Sopenharmony_ci1. The system does not have sufficient memory for mapping.
38e41f4b71Sopenharmony_ci2. Invalid instances are not destroyed in time to release the memory.
39e41f4b71Sopenharmony_ci
40e41f4b71Sopenharmony_ci**Procedure**
41e41f4b71Sopenharmony_ci
42e41f4b71Sopenharmony_ci1. Destroy the existing instances.
43e41f4b71Sopenharmony_ci2. Create a new instance. If the creation fails, stop related operations.
44e41f4b71Sopenharmony_ci
45e41f4b71Sopenharmony_ci## 24700103 Unsupported State
46e41f4b71Sopenharmony_ci
47e41f4b71Sopenharmony_ci**Error Message**
48e41f4b71Sopenharmony_ci
49e41f4b71Sopenharmony_ciUnsupported state.
50e41f4b71Sopenharmony_ci
51e41f4b71Sopenharmony_ci**Description**
52e41f4b71Sopenharmony_ci
53e41f4b71Sopenharmony_ciThis operation is not allowed in the current state.
54e41f4b71Sopenharmony_ci
55e41f4b71Sopenharmony_ci**Possible Causes**
56e41f4b71Sopenharmony_ci
57e41f4b71Sopenharmony_ciThe status of the device certificate or media key is abnormal.
58e41f4b71Sopenharmony_ci
59e41f4b71Sopenharmony_ci**Procedure**
60e41f4b71Sopenharmony_ci
61e41f4b71Sopenharmony_ci1. Check whether this operation is supported in the current state.
62e41f4b71Sopenharmony_ci2. Call the API to request a device certificate or media key in the correct state.
63e41f4b71Sopenharmony_ci
64e41f4b71Sopenharmony_ci## 24700104 Too Many MediaKeySystem Instances
65e41f4b71Sopenharmony_ci
66e41f4b71Sopenharmony_ci**Error Message**
67e41f4b71Sopenharmony_ci
68e41f4b71Sopenharmony_ciToo many MediaKeySystem streams.
69e41f4b71Sopenharmony_ci
70e41f4b71Sopenharmony_ci**Description**
71e41f4b71Sopenharmony_ci
72e41f4b71Sopenharmony_ciThe number of **MediaKeySystem** instances reaches the upper limit.
73e41f4b71Sopenharmony_ci
74e41f4b71Sopenharmony_ci**Possible Causes**
75e41f4b71Sopenharmony_ci
76e41f4b71Sopenharmony_ciInvalid **MediaKeySystem** instances are not released in time.
77e41f4b71Sopenharmony_ci
78e41f4b71Sopenharmony_ci**Procedure**
79e41f4b71Sopenharmony_ci
80e41f4b71Sopenharmony_ciRelease **MediaKeySystem** instances that are no longer used.
81e41f4b71Sopenharmony_ci
82e41f4b71Sopenharmony_ci## 24700105 Too Many MediaKeySession Instances
83e41f4b71Sopenharmony_ci
84e41f4b71Sopenharmony_ci**Error Message**
85e41f4b71Sopenharmony_ci
86e41f4b71Sopenharmony_ciToo many MediaKeySession streams.
87e41f4b71Sopenharmony_ci
88e41f4b71Sopenharmony_ci**Description**
89e41f4b71Sopenharmony_ci
90e41f4b71Sopenharmony_ciThe number of **MediaKeySession** instances reaches the upper limit.
91e41f4b71Sopenharmony_ci
92e41f4b71Sopenharmony_ci**Possible Causes**
93e41f4b71Sopenharmony_ci
94e41f4b71Sopenharmony_ciInvalid **MediaKeySession** instances are not released in time.
95e41f4b71Sopenharmony_ci
96e41f4b71Sopenharmony_ci**Procedure**
97e41f4b71Sopenharmony_ci
98e41f4b71Sopenharmony_ciRelease **MediaKeySession** instances that are no longer used.
99e41f4b71Sopenharmony_ci
100e41f4b71Sopenharmony_ci## 24700201 Service Error
101e41f4b71Sopenharmony_ci
102e41f4b71Sopenharmony_ci**Error Message**
103e41f4b71Sopenharmony_ci
104e41f4b71Sopenharmony_ciFatal service error, for example, service died.
105e41f4b71Sopenharmony_ci
106e41f4b71Sopenharmony_ci**Description**
107e41f4b71Sopenharmony_ci
108e41f4b71Sopenharmony_ciThe IPC service is abnormal.
109e41f4b71Sopenharmony_ci
110e41f4b71Sopenharmony_ci**Possible Causes**
111e41f4b71Sopenharmony_ci
112e41f4b71Sopenharmony_ciThe system processing is abnormal, for example, system service restart or IPC exceptions.
113e41f4b71Sopenharmony_ci
114e41f4b71Sopenharmony_ci**Procedure**
115e41f4b71Sopenharmony_ci
116e41f4b71Sopenharmony_ciCreate the service again.
117