Changeset 1569a9b in mainline for uspace/app/trace/trace.c


Ignore:
Timestamp:
2017-12-24T16:40:33Z (6 years ago)
Author:
GitHub <noreply@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
48fd597
Parents:
a1026da
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2017-12-24 16:40:33)
git-committer:
GitHub <noreply@…> (2017-12-24 16:40:33)
Message:

The "not-so-obvious" error handling tweaks. (#9)

Some more changes to enable type-checking with errno_t. Some of the "fixes" here don't quite feel right, but a proper solution would be a more elaborate refactoring of the surrounding code.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/app/trace/trace.c

    ra1026da r1569a9b  
    260260
    261261
    262 static void print_sc_retval(int retval, val_type_t val_type)
     262static void print_sc_retval(sysarg_t retval, val_type_t val_type)
    263263{
    264264        printf(" -> ");
     
    296296        IPC_SET_ARG5(call, 0);
    297297
    298         ipcp_call_out(phoneid, &call, sc_rc);
    299 }
    300 
    301 static void sc_ipc_call_async_slow(sysarg_t *sc_args, sysarg_t sc_rc)
     298        ipcp_call_out(phoneid, &call, 0);
     299}
     300
     301static void sc_ipc_call_async_slow(sysarg_t *sc_args, int sc_rc)
    302302{
    303303        ipc_call_t call;
    304304        int rc;
    305305
    306         if (sc_rc != (sysarg_t) EOK)
     306        if (sc_rc != EOK)
    307307                return;
    308308
     
    310310        rc = udebug_mem_read(sess, &call.args, sc_args[1], sizeof(call.args));
    311311
    312         if (rc >= 0) {
    313                 ipcp_call_out(sc_args[0], &call, sc_rc);
     312        if (rc == EOK) {
     313                ipcp_call_out(sc_args[0], &call, 0);
    314314        }
    315315}
     
    581581               
    582582                if (!console_get_event(console, &event))
    583                         return -1;
     583                        return EINVAL;
    584584               
    585585                if (event.type == CEV_KEY) {
Note: See TracChangeset for help on using the changeset viewer.