summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeith Packard <keithp@keithp.com>2009-04-22 15:48:14 -0700
committerKeith Packard <keithp@keithp.com>2009-04-22 15:48:14 -0700
commitada6dea04b94be016598566c4c13e6105aaec353 (patch)
tree3c3e1cc2aa56fdfdb1bb6f4a634ba57fb1426652
parent0a1b2297ee9f5bbb918bd72f26088a3e0b84839a (diff)
Clean up task list formatting
-rw-r--r--ao_task.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/ao_task.c b/ao_task.c
index 878724c5..47db1277 100644
--- a/ao_task.c
+++ b/ao_task.c
@@ -193,13 +193,15 @@ ao_task_info(void)
{
uint8_t i;
uint8_t pc_loc;
+ __xdata struct ao_task *task;
for (i = 0; i < ao_num_tasks; i++) {
- pc_loc = ao_tasks[i]->stack_count - 17;
- printf("%-8s: wchan %04x pc %04x\n",
- ao_tasks[i]->name,
- (int16_t) ao_tasks[i]->wchan,
- (ao_tasks[i]->stack[pc_loc]) | (ao_tasks[i]->stack[pc_loc+1] << 8));
+ task = ao_tasks[i];
+ pc_loc = task->stack_count - 17;
+ printf("%12s: wchan %04x pc %04x\n",
+ (char *) task->name,
+ (int16_t) task->wchan,
+ (task->stack[pc_loc]) | (task->stack[pc_loc+1] << 8));
}
}