Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/cap/cap.c

    rb7fd2a0 r82d515e9  
    124124 * @param task  Task for which to allocate the info structure.
    125125 */
    126 errno_t caps_task_alloc(task_t *task)
     126int caps_task_alloc(task_t *task)
    127127{
    128128        task->cap_info = (cap_info_t *) malloc(sizeof(cap_info_t),
     
    257257 * @param task  Task for which to allocate the new capability.
    258258 *
    259  * @param[out] handle  New capability handle on success.
    260  *
    261  * @return An error code in case of error.
    262  */
    263 errno_t cap_alloc(task_t *task, cap_handle_t *handle)
     259 * @return New capability handle on success.
     260 * @return Negative error code in case of error.
     261 */
     262cap_handle_t cap_alloc(task_t *task)
    264263{
    265264        cap_t *cap = NULL;
     265        cap_handle_t handle;
    266266
    267267        /*
     
    293293
    294294        cap->state = CAP_STATE_ALLOCATED;
    295         *handle = cap->handle;
    296         mutex_unlock(&task->cap_info->lock);
    297 
    298         return EOK;
     295        handle = cap->handle;
     296        mutex_unlock(&task->cap_info->lock);
     297
     298        return handle;
    299299}
    300300
Note: See TracChangeset for help on using the changeset viewer.