summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJaemin Ryu <jm77.ryu@samsung.com>2017-10-31 14:36:21 +0900
committersangwan kwon <sangwan.kwon@samsung.com>2017-10-31 06:28:25 +0000
commit74144e16cba3298336ddeba1df6e51c9221f6fbf (patch)
treea040869cf538080f011d047bad7ced0fb4d41555
parentab991e6b0d63be9655db0d4c9e316f7102250b60 (diff)
downloaddpm-application-74144e16cba3298336ddeba1df6e51c9221f6fbf.tar.gz
dpm-application-74144e16cba3298336ddeba1df6e51c9221f6fbf.tar.bz2
dpm-application-74144e16cba3298336ddeba1df6e51c9221f6fbf.zip
Change-Id: I55f310f624b7687529e386270eca1db22c1b8a09 Signed-off-by: Jaemin Ryu <jm77.ryu@samsung.com>
-rw-r--r--api/application.cpp6
-rw-r--r--api/application.h2
2 files changed, 7 insertions, 1 deletions
diff --git a/api/application.cpp b/api/application.cpp
index fc785a1..ae1e77f 100644
--- a/api/application.cpp
+++ b/api/application.cpp
@@ -21,6 +21,12 @@
#include "application.h"
+#define RET_ON_FAILURE(cond, ret) \
+{ \
+ if (!(cond)) \
+ return (ret); \
+}
+
EXPORT_API int dpm_application_set_mode_restriction(device_policy_manager_h handle, int mode)
{
RET_ON_FAILURE(handle, DPM_ERROR_INVALID_PARAMETER);
diff --git a/api/application.h b/api/application.h
index bc71b94..be0f1f7 100644
--- a/api/application.h
+++ b/api/application.h
@@ -17,7 +17,7 @@
#ifndef __CAPI_DPM_APPLICATION_POLICY_H__
#define __CAPI_DPM_APPLICATION_POLICY_H__
-typedef void * device_policy_manager_h;
+#include <dpm/device-policy-manager.h>
/**
* @file application.h