Changeset 8c85f0f in mainline for uspace/lib/posix/src/time.c


Ignore:
Timestamp:
2018-08-24T19:02:59Z (6 years ago)
Author:
Jakub Jermar <jakub@…>
Children:
378d349
Parents:
f33c989e
Message:

Fix missing include

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/posix/src/time.c

    rf33c989e r8c85f0f  
    220220        case CLOCK_REALTIME:
    221221                res->tv_sec = 0;
    222                 res->tv_nsec = 1000; /* Microsecond resolution. */
     222                res->tv_nsec = USEC2NSEC(1); /* Microsecond resolution. */
    223223                return 0;
    224224        default:
     
    245245                gettimeofday(&tv, NULL);
    246246                tp->tv_sec = tv.tv_sec;
    247                 tp->tv_nsec = tv.tv_usec * 1000;
     247                tp->tv_nsec = USEC2NSEC(tv.tv_usec);
    248248                return 0;
    249249        default:
     
    301301                }
    302302                if (rqtp->tv_nsec != 0) {
    303                         fibril_usleep(rqtp->tv_nsec / 1000);
     303                        fibril_usleep(NSEC2USEC(rqtp->tv_nsec));
    304304                }
    305305                return 0;
Note: See TracChangeset for help on using the changeset viewer.