Question
My Tizen application was rejected because it uses the __dlog_print() function, which is listed in core_whitelist.txt.
This is somewhat surprising because:
- I've been using the same logging code without issues until now
- The only recent change was adding the LAME library for audio encoding
- I followed the official guide for using LAME: Encoding Audio Files with LAME
Has anyone else encountered this issue with __dlog_print() or when using the LAME library?
Answer
Problem Understanding
The rejection occurs because __dlog_print() is an undocumented internal API that should not be used in production applications. While it might have worked previously, Tizen's app validation process now explicitly checks for such restricted APIs.
Solution Methods
-
Replace __dlog_print() with the official dlog_print() API
- This is the standard logging function that should be used instead
- Example: Change
__dlog_print(LOG_TAG, "message")todlog_print(DLOG_INFO, LOG_TAG, "message")
-
Check for indirect usage through libraries
- Some third-party libraries might internally use __dlog_print()
- Review all included libraries and their logging implementations
-
Use standard logging macros
- Instead of direct API calls, consider using standard macros like:
#define LOGI(fmt, args...) dlog_print(DLOG_INFO, LOG_TAG, fmt, ##args)
- Instead of direct API calls, consider using standard macros like:
Code Examples
// Bad (will cause rejection)
__dlog_print(LOG_TAG, "This is a log message");
// Good (approved)
dlog_print(DLOG_INFO, LOG_TAG, "This is a log message");
// Better (using standard macro)
#define LOGI(fmt, args...) dlog_print(DLOG_INFO, LOG_TAG, fmt, ##args)
LOGI("This is a log message with value: %d", some_value);
Additional Tips
- Always use documented APIs from the official Tizen documentation
- When adding third-party libraries, check their logging implementations
- The LAME library itself doesn't cause this issue, but might include problematic logging code
- For reference, see the official logging documentation on Samsung Tizen OS