diff --git a/experimental/ecdb/trunk/src/ecdb_burn.c b/experimental/ecdb/trunk/src/ecdb_burn.c index 908ce6a7..8a606b6d 100644 --- a/experimental/ecdb/trunk/src/ecdb_burn.c +++ b/experimental/ecdb/trunk/src/ecdb_burn.c @@ -183,16 +183,15 @@ ecdb_drive_progress_update(void *data) } else if (stat == BURN_DRIVE_IDLE) { - ecore_pipe_write(proj->pipe, NULL, 0); + ecore_pipe_write(proj->pipe, "AC", + sizeof("AC")); ecore_pipe_del(proj->pipe); /* Call the finished event handler here */ pthread_exit(NULL); break; } - // Arg... too tired to figure this out now - //ecore_pipe_write(proj->pipe, &p, sizeof(p)); - printf("%d/%d\n", p.sector, p.sectors); + ecore_pipe_write(proj->pipe, &p, sizeof(p)); sleep(1); } } diff --git a/experimental/ecdb/trunk/src/ecdb_erase.c b/experimental/ecdb/trunk/src/ecdb_erase.c index d6b4a2f9..8bf03007 100644 --- a/experimental/ecdb/trunk/src/ecdb_erase.c +++ b/experimental/ecdb/trunk/src/ecdb_erase.c @@ -92,25 +92,26 @@ ecdb_erase_disc(Ecdb_Erase_Project *proj) static void ecdb_erase_progress_handler(void *data, void *buffer, unsigned int nbyte) { - BurnProgress *p = buffer; + BurnProgress *p; Evas_Object *swallow; char buf[1024]; + char *text = buffer; - // Is this correct? - // Check this - if (sizeof(buffer) == sizeof(BurnProgress)) - { - p = buffer; - } - else + if ((nbyte != sizeof(BurnProgress)) || (!strcmp(text, "AC"))) { ecore_event_add(ECDB_DRIVE_ACTION_FINISHED, NULL, NULL, NULL); return; } + else + { + p = buffer; + text = NULL; + } swallow = evas_object_name_find(ecore_evas_get(em->main_win_ee), "erase_page"); snprintf(buf, sizeof(buf), "%d/%d", p->sector, p->sectors); + printf("buf: %s\n", buf); edje_object_part_text_set(swallow, "progress_text", buf); }