Changeset 46577995 in mainline for uspace/app/pkg/pkg.c


Ignore:
Timestamp:
2018-01-04T20:50:52Z (8 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Children:
e211ea04
Parents:
facacc71
git-author:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-01-04 20:47:53)
git-committer:
Jiří Zárevúcky <zarevucky.jiri@…> (2018-01-04 20:50:52)
Message:

Use errno_t in all uspace and kernel code.

Change type of every variable, parameter and return value that holds an
<errno.h> constant to either errno_t (the usual case), or sys_errno_t
(some places in kernel). This is for the purpose of self-documentation,
as well as for type-checking with a bit of type definition hackery.

After this commit, HelenOS is free of code that mixes error codes with non-error
values on the assumption that error codes are negative.

File:
1 edited

Legend:

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

    rfacacc71 r46577995  
    4949}
    5050
    51 static int cmd_runl(const char *path, ...)
     51static errno_t cmd_runl(const char *path, ...)
    5252{
    5353        va_list ap;
     
    6565        task_id_t id;
    6666        task_wait_t wait;
    67         int rc = task_spawn(&id, &wait, path, cnt, ap);
     67        errno_t rc = task_spawn(&id, &wait, path, cnt, ap);
    6868        va_end(ap);
    6969
     
    100100
    101101
    102 static int pkg_install(int argc, char *argv[])
     102static errno_t pkg_install(int argc, char *argv[])
    103103{
    104104        char *pkg_name;
     
    106106        char *fname;
    107107        char *fnunpack;
    108         int rc;
     108        errno_t rc;
    109109        int ret;
    110110
     
    181181{
    182182        char *cmd;
    183         int rc;
     183        errno_t rc;
    184184
    185185        if (argc < 2) {
Note: See TracChangeset for help on using the changeset viewer.