home *** CD-ROM | disk | FTP | other *** search
/ Il CD di internet / CD.iso / SOURCE / D / LIBC / LIBC-4.6 / LIBC-4 / libc-linux / sysdeps / linux / __utimes.c < prev    next >
Encoding:
C/C++ Source or Header  |  1994-08-30  |  350 b   |  22 lines

  1. #include <utime.h>
  2. #include <sys/time.h>
  3.  
  4. int __utimes(char *path, struct timeval *tvp)
  5. {
  6.     struct utimbuf buf, *times;
  7.  
  8.     if (tvp) {
  9.         times = &buf;
  10.         times->actime = tvp[0].tv_sec;
  11.         times->modtime = tvp[1].tv_sec;
  12.     }
  13.     else
  14.         times = NULL;
  15.     return utime(path, times);
  16. }
  17.  
  18. #include <gnu-stabs.h>
  19. #ifdef weak_alias
  20. weak_alias (__utimes, utimes);
  21. #endif
  22.