17c478bd9Sstevel@tonic-gate /*
2*9525b14bSRao Shoaib  * Copyright (c) 2004 by Internet Systems Consortium, Inc. ("ISC")
37c478bd9Sstevel@tonic-gate  * Copyright (c) 1997,1999 by Internet Software Consortium.
47c478bd9Sstevel@tonic-gate  *
57c478bd9Sstevel@tonic-gate  * Permission to use, copy, modify, and distribute this software for any
67c478bd9Sstevel@tonic-gate  * purpose with or without fee is hereby granted, provided that the above
77c478bd9Sstevel@tonic-gate  * copyright notice and this permission notice appear in all copies.
87c478bd9Sstevel@tonic-gate  *
9*9525b14bSRao Shoaib  * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES
10*9525b14bSRao Shoaib  * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11*9525b14bSRao Shoaib  * MERCHANTABILITY AND FITNESS.  IN NO EVENT SHALL ISC BE LIABLE FOR
12*9525b14bSRao Shoaib  * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13*9525b14bSRao Shoaib  * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14*9525b14bSRao Shoaib  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT
15*9525b14bSRao Shoaib  * OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
167c478bd9Sstevel@tonic-gate  */
177c478bd9Sstevel@tonic-gate 
187c478bd9Sstevel@tonic-gate #include "port_before.h"
197c478bd9Sstevel@tonic-gate 
207c478bd9Sstevel@tonic-gate #include <sys/types.h>
217c478bd9Sstevel@tonic-gate #include <sys/time.h>
227c478bd9Sstevel@tonic-gate #include <utime.h>
237c478bd9Sstevel@tonic-gate 
247c478bd9Sstevel@tonic-gate #include "port_after.h"
257c478bd9Sstevel@tonic-gate 
267c478bd9Sstevel@tonic-gate #ifndef NEED_UTIMES
277c478bd9Sstevel@tonic-gate int __bind_utimes_unneeded;
287c478bd9Sstevel@tonic-gate #else
297c478bd9Sstevel@tonic-gate 
307c478bd9Sstevel@tonic-gate int
__utimes(char * filename,struct timeval * tvp)317c478bd9Sstevel@tonic-gate __utimes(char *filename, struct timeval *tvp) {
327c478bd9Sstevel@tonic-gate 	struct utimbuf utb;
337c478bd9Sstevel@tonic-gate 
347c478bd9Sstevel@tonic-gate 	utb.actime = (time_t)tvp[0].tv_sec;
357c478bd9Sstevel@tonic-gate 	utb.modtime = (time_t)tvp[1].tv_sec;
367c478bd9Sstevel@tonic-gate 	return (utime(filename, &utb));
377c478bd9Sstevel@tonic-gate }
387c478bd9Sstevel@tonic-gate 
397c478bd9Sstevel@tonic-gate #endif /* NEED_UTIMES */
40*9525b14bSRao Shoaib /*! \file */
41