From: Yunhee Seo Date: Thu, 17 Oct 2024 03:46:42 +0000 (+0900) Subject: Add extern C definition to notifier.h X-Git-Tag: accepted/tizen/8.0/unified/20250228.161148^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fheads%2Faccepted%2Ftizen_8.0_unified;p=platform%2Fcore%2Fsystem%2Flibsyscommon.git Add extern C definition to notifier.h Although plugin-api-deviced header has extern C definition, there was no extern C definition in the notifier header. Thus, it was hard to implement utilizing notifier releated logic from the C++ environment. To support notifier usage in the C++ environment, this is necessary. Change-Id: I41b58beba054746dcfb21fe7cf7ed7c2193da440 Signed-off-by: Yunhee Seo --- diff --git a/include/libsyscommon/notifier.h b/include/libsyscommon/notifier.h index f88d22f..827eb3e 100644 --- a/include/libsyscommon/notifier.h +++ b/include/libsyscommon/notifier.h @@ -23,6 +23,10 @@ #ifndef __SYSCOMMON_NOTIFIER_H__ #define __SYSCOMMON_NOTIFIER_H__ +#ifdef __cplusplus +extern "C" { +#endif + typedef int (*syscommon_notifier_cb) (void *notify_data); typedef int (*syscommon_notifier_udata_cb) (void *notify_data, void *user_data); typedef void (*syscommon_notifier_destroy_cb) (void *user_data); @@ -74,4 +78,8 @@ void syscommon_notifier_emit_notify(int type, void *notify_data); * Notification after the first one is ignored. */ void syscommon_notifier_emit_notify_once(int type, void *notify_data); +#ifdef __cplusplus +} +#endif + #endif /* __SYSCOMMON_NOTIFIER_H__ */