* @since_tizen @if MOBILE 3.0 @elseif WEARABLE 2.3.2 @endif
*
* @param[in] tts The TTS handle
- * @param]in] callback The callback function to register
+ * @param[in] callback The callback function to register
* @param[in] user_data The user data to be passed to the callback function
*
* @return 0 on success, otherwise a negative error value
}
#endif
+/**
+ * @}@}
+ */
+
#endif /* __TTS_H__ */
{
bundle *b = NULL;
ttsd_mode_e mode = TTSD_MODE_DEFAULT;
+ int ret = TTSE_ERROR_NONE;
b = bundle_import_from_argv(argc, argv);
if (NULL != b) {
SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to get data from bundle");
}
bundle_free(b);
+ val = NULL;
} else {
SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to get bundle");
}
if (!ecore_init()) {
SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to initialize Ecore");
- return -1;
+ return TTSE_ERROR_OPERATION_FAILED;
}
if (0 != ttsd_dbus_open_connection()) {
SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to open dbus connection");
- return -1;
+ ecore_shutdown();
+ return TTSE_ERROR_OPERATION_FAILED;
}
- if (0 != ttsd_initialize(callback)) {
+ ret = ttsd_initialize(callback);
+ if (0 != ret) {
SLOG(LOG_ERROR, tts_tag(), "[ERROR] Fail to initialize");
- return -1;
+ ttsd_dbus_close_connection();
+ ecore_shutdown();
+ return ret;
}
if (0 != ttsd_network_initialize()) {
SLOG(LOG_DEBUG, tts_tag(), "====");
SLOG(LOG_DEBUG, tts_tag(), "");
- return 0;
+ return TTSE_ERROR_NONE;
}
int ttse_get_speed_range(int* min, int* normal, int* max)