summaryrefslogtreecommitdiff
path: root/apps/plugins/test_codec.c
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2008-12-10 08:57:10 +0000
committerMichael Sevakis <jethead71@rockbox.org>2008-12-10 08:57:10 +0000
commit8cfbd3604fac14f629244e521ad24ffa9938c790 (patch)
tree16dc096519b8b537bb7d4b73e0c97f5f33ee752b /apps/plugins/test_codec.c
parent40ff47c7eea41ac893d7af5c5b97ace52a5ffade (diff)
downloadrockbox-8cfbd3604fac14f629244e521ad24ffa9938c790.tar.gz
rockbox-8cfbd3604fac14f629244e521ad24ffa9938c790.zip
Use cookies for thread identification instead of pointers directly which gives a buffer against wrongly identifying a thread when the slot is recycled (which has been nagging me for awhile). A slot gets 255 uses before it repeats. Everything gets incompatible so a full update is required.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19377 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/test_codec.c')
-rw-r--r--apps/plugins/test_codec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/plugins/test_codec.c b/apps/plugins/test_codec.c
index b1f5aff385..17effd8dfd 100644
--- a/apps/plugins/test_codec.c
+++ b/apps/plugins/test_codec.c
@@ -525,7 +525,7 @@ static enum plugin_status test_track(const char* filename)
525 long ticks; 525 long ticks;
526 unsigned long speed; 526 unsigned long speed;
527 unsigned long duration; 527 unsigned long duration;
528 struct thread_entry* codecthread_id; 528 unsigned int codecthread_id;
529 const char* ch; 529 const char* ch;
530 530
531 /* Display filename (excluding any path)*/ 531 /* Display filename (excluding any path)*/
@@ -590,7 +590,7 @@ static enum plugin_status test_track(const char* filename)
590 590
591 if ((codecthread_id = rb->create_thread(codec_thread, 591 if ((codecthread_id = rb->create_thread(codec_thread,
592 codec_stack, codec_stack_size, 0, "testcodec" 592 codec_stack, codec_stack_size, 0, "testcodec"
593 IF_PRIO(,PRIORITY_PLAYBACK) IF_COP(, CPU))) == NULL) 593 IF_PRIO(,PRIORITY_PLAYBACK) IF_COP(, CPU))) == 0)
594 { 594 {
595 log_text("Cannot create codec thread!",true); 595 log_text("Cannot create codec thread!",true);
596 goto exit; 596 goto exit;