Changeset 24345a5 in mainline for kernel/generic/src/proc/task.c


Ignore:
Timestamp:
2008-11-08T10:01:59Z (17 years ago)
Author:
Jiri Svoboda <jirik.svoboda@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
24d6efc
Parents:
7faabb7
Message:

Set meaningful names for loaded programs. Now 'tasks' kconsole command is much less obscure.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/proc/task.c

    r7faabb7 r24345a5  
    131131 *
    132132 * @param as            Task's address space.
    133  * @param name          Symbolic name.
     133 * @param name          Symbolic name (a copy is made).
    134134 *
    135135 * @return              New task's structure.
     
    149149        list_initialize(&ta->th_head);
    150150        ta->as = as;
    151         ta->name = name;
     151
     152        memcpy(ta->name, name, TASK_NAME_BUFLEN);
     153        ta->name[TASK_NAME_BUFLEN - 1] = '\0';
     154
    152155        atomic_set(&ta->refcount, 0);
    153156        atomic_set(&ta->lifecount, 0);
Note: See TracChangeset for help on using the changeset viewer.