EXPORT_API int appcore_base_on_receive(aul_type type, bundle *b)
{
- int ret;
- const char **tep_path;
- int len = 0;
- int i;
const char *bg;
int dummy = 0;
switch (type) {
case AUL_START:
_DBG("[APP %d] AUL event: AUL_START", getpid());
- tep_path = bundle_get_str_array(b, AUL_TEP_PATH, &len);
- if (tep_path) {
- for (i = 0; i < len; i++) {
- ret = aul_check_tep_mount(tep_path[i]);
- if (ret == -1) {
- _ERR("mount request not completed within 1 sec");
- exit(-1);
- }
- }
- }
-
if (TIZEN_FEATURE_BACKGROUND_MANAGEMENT) {
bg = bundle_get_val(b, AUL_K_ALLOWED_BG);
if (bg && !strcmp(bg, "ALLOWED_BG")) {
EXPORT_API int appcore_base_on_create(void)
{
int r;
+ bundle *b;
+ int ret;
+ int i;
+ int len = 0;
+ const char **tep_path;
+
r = aul_launch_init(__context.ops.receive, NULL);
if (r < 0) {
_ERR("Aul init failed: %d", r);
return -1;
}
+ b = bundle_import_from_argv(__context.argc, __context.argv);
+ if (b == NULL) {
+ _ERR("Failed to import bundle");
+ return 0;
+ }
+
+ tep_path = bundle_get_str_array(b, AUL_TEP_PATH, &len);
+ if (tep_path) {
+ for (i = 0; i < len; i++) {
+ ret = aul_check_tep_mount(tep_path[i]);
+ if (ret == -1) {
+ _ERR("mount request not completed within 1 sec");
+ exit(-1);
+ }
+ }
+ }
+
+ bundle_free(b);
+
return 0;
}