Skip to content

Commit e17eda7

Browse files
authored
RDKEMW-6718: Update HdcpProfile.cpp
1 parent 8f69cc2 commit e17eda7

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

HdcpProfile/HdcpProfile.cpp

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ namespace WPEFramework
4545
SERVICE_REGISTRATION(HdcpProfile, API_VERSION_NUMBER_MAJOR, API_VERSION_NUMBER_MINOR, API_VERSION_NUMBER_PATCH);
4646

4747
HdcpProfile::HdcpProfile()
48-
: _service(nullptr)
48+
: PluginHost::JSONRPCErrorAssessor<PluginHost::JSONRPCErrorAssessorTypes::FunctionCallbackType>(HdcpProfile::OnJSONRPCError)
49+
,_service(nullptr)
4950
, _connectionId(0)
5051
, _hdcpProfile(nullptr)
5152
, _hdcpProfileNotification(this)
@@ -163,6 +164,16 @@ namespace WPEFramework
163164
return ("This HdcpProfile Plugin facilitates to persist event data for monitoring applications");
164165
}
165166

167+
uint32_t HdcpProfile::OnJSONRPCError(const Core::JSONRPC::Context&, const string& method, const string& parameters, const uint32_t errorcode, string& errormessage) {
168+
LOGINFO("DBG:OnJSONRPCERROR");
169+
if(method == _T("getHDCPStatus"))
170+
{
171+
LOGINFO("DBG-Inside If");
172+
errormessage = error_strings[errorcode-ERROR_BASE];
173+
}
174+
return errorcode;
175+
}
176+
166177
void HdcpProfile::Deactivated(RPC::IRemoteConnection *connection)
167178
{
168179
if (connection->Id() == _connectionId)

0 commit comments

Comments
 (0)