Fork us on GitHub Follow us on Facebook Follow us on Twitter

Changeset f04b5b3 in mainline


Ignore:
Timestamp:
2017-12-21T20:24:23Z (4 years ago)
Author:
Jiří Zárevúcky <zarevucky.jiri@…>
Branches:
lfn, master
Children:
a1026da, bad8d41
Parents:
39b54fe
Message:

Fix error propagating in closedir().

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/dirent.c

    r39b54fe rf04b5b3  
    114114int closedir(DIR *dirp)
    115115{
    116         int rc;
    117        
    118         rc = vfs_put(dirp->fd);
     116        int rc = vfs_put(dirp->fd);
    119117        free(dirp);
    120118
    121         /* On error errno was set by close() */
    122         return rc;
     119        if (rc == EOK) {
     120                return 0;
     121        } else {
     122                errno = rc;
     123                return -1;
     124        }
    123125}
    124126
Note: See TracChangeset for help on using the changeset viewer.