10Sstevel@tonic-gate #ifndef LINT 2*11038SRao.Shoaib@Sun.COM static const char rcsid[] = "$Id: setitimer.c,v 1.2 2005/04/27 04:56:12 sra Exp $"; 30Sstevel@tonic-gate #endif 40Sstevel@tonic-gate 50Sstevel@tonic-gate #include "port_before.h" 60Sstevel@tonic-gate 70Sstevel@tonic-gate #include <sys/time.h> 80Sstevel@tonic-gate 90Sstevel@tonic-gate #include "port_after.h" 100Sstevel@tonic-gate 11*11038SRao.Shoaib@Sun.COM /*% 120Sstevel@tonic-gate * Setitimer emulation routine. 130Sstevel@tonic-gate */ 140Sstevel@tonic-gate #ifndef NEED_SETITIMER 150Sstevel@tonic-gate int __bindcompat_setitimer; 160Sstevel@tonic-gate #else 170Sstevel@tonic-gate 180Sstevel@tonic-gate int __setitimer(int which,const struct itimerval * value,struct itimerval * ovalue)190Sstevel@tonic-gate__setitimer(int which, const struct itimerval *value, 200Sstevel@tonic-gate struct itimerval *ovalue) 210Sstevel@tonic-gate { 220Sstevel@tonic-gate if (alarm(value->it_value.tv_sec) >= 0) 230Sstevel@tonic-gate return (0); 240Sstevel@tonic-gate else 250Sstevel@tonic-gate return (-1); 260Sstevel@tonic-gate } 270Sstevel@tonic-gate #endif 28*11038SRao.Shoaib@Sun.COM 29*11038SRao.Shoaib@Sun.COM /*! \file */ 30