diff example/renew_task/spe/Renew2.cc @ 467:44c0bce54dcf

fix all examples. test_render is not working now.
author Shinji KONO <kono@ie.u-ryukyu.ac.jp>
date Thu, 01 Oct 2009 19:25:25 +0900
parents b89ba1d96fff
children ab866bc8a624
line wrap: on
line diff
--- a/example/renew_task/spe/Renew2.cc	Thu Oct 01 17:33:58 2009 +0900
+++ b/example/renew_task/spe/Renew2.cc	Thu Oct 01 19:25:25 2009 +0900
@@ -6,20 +6,20 @@
 /* これは必須 */
 SchedDefineTask(Renew2);
 
-int
-Renew2::run(void *rbuf, void *wbuf)
+static int
+run(SchedTask *s, void *rbuf, void *wbuf)
 {
-    SpeProfile *profile = (SpeProfile*) global_get(0);
+    SpeProfile *profile = (SpeProfile*) s->global_get(0);
     profile->ProfStop();
     profile->ProfPrint();
 
-    printf("[SPE] ** running Renew2\n");
+    s->printf("[SPE] ** running Renew2\n");
 
-    printf("[SPE] Create Task : Renew3\n");
-    TaskPtr nextTask =  create_task(RENEW3);
-    wait_task(nextTask);
+    s->printf("[SPE] Create Task : Renew3\n");
+    TaskPtr nextTask =  s->create_task(RENEW3);
+    s->wait_task(nextTask);
     
-    printf("[SPE] ** finish  Renew2\n\n");
+    s->printf("[SPE] ** finish  Renew2\n\n");
 
     profile->ProfStart();