1N/A * Copyright (c) 2000-2002, 2004 Sendmail, Inc. and its suppliers. 1N/A * All rights reserved. 1N/A * Copyright (c) 1990, 1993 1N/A * The Regents of the University of California. All rights reserved. 1N/A * This code is derived from software contributed to Berkeley by 1N/A * By using this file, you agree to the terms and conditions set 1N/A * forth in the LICENSE file which can be found at the top level of 1N/A * the sendmail distribution. 1N/A#
pragma ident "%Z%%M% %I% %E% SMI" 1N/A** CLOSEALRM -- handler when timeout activated for sm_io_close() 1N/A** Returns flow of control to where setjmp(CloseTimeOut) was set. 1N/A** returns flow of control to setjmp(CloseTimeOut). 1N/A** NOTE: THIS CAN BE CALLED FROM A SIGNAL HANDLER. DO NOT ADD 1N/A** ANYTHING TO THIS ROUTINE UNLESS YOU KNOW WHAT YOU ARE 1N/A** fp -- file pointer to be closed 1N/A** timeout -- maximum time allowed to perform the close (millisecs) 1N/A** -1 on failure and sets errno 1N/A** file pointer 'fp' will no longer be valid. 1N/A /* XXX this won't be reached if above macro is active */ 1N/A /* no close function! */ 1N/A /* decrement file pointer open count */ 1N/A /* Okay, this is where we set the timeout. */ 1N/A /* No more duplicates of file pointer. Flush buffer and close */ 1N/A /* sm_flush() has updated to.it_value for the time it's used */ 1N/A /* We're back. So undo our timeout and handler */