Ignore:
Timestamp:
2018-01-30T03:20:45Z (8 years ago)
Author:
Jenda <jenda.jzqk73@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
5a6cc679
Parents:
8bfb163 (diff), 6a5d05b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge commit '6a5d05bd2551e64111bea4f9332dd7448c26ce84' into forwardport

Separate return value from error code in gen_irq_code*().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/ipc/ops/conctmeto.c

    r8bfb163 r132ab5d1  
    4242static int request_preprocess(call_t *call, phone_t *phone)
    4343{
    44         cap_handle_t phone_handle = phone_alloc(TASK);
     44        cap_handle_t phone_handle;
     45        int rc = phone_alloc(TASK, &phone_handle);
    4546
    46         /* Remember the phone capability or the error. */
    47         call->priv = phone_handle;
    48         if (phone_handle < 0)
    49                 return phone_handle;
     47        /* Remember the phone capability or that an error occured. */
     48        call->priv = (rc == EOK) ? phone_handle : -1;
     49
     50        if (rc != EOK) {
     51                return rc;
     52        }
    5053
    5154        /* Set arg5 for server */
     
    6164{
    6265        cap_handle_t phone_handle = (cap_handle_t) call->priv;
     66
     67        if (phone_handle < 0) {
     68                return EOK;
     69        }
     70
    6371        phone_dealloc(phone_handle);
    6472        /* Hand over reference from ARG5 to phone->kobject */
Note: See TracChangeset for help on using the changeset viewer.