imapext-2007
diff src/osdep/nt/yunchan.h @ 0:ada5e610ab86
imap-2007e
author | yuuji@gentei.org |
---|---|
date | Mon, 14 Sep 2009 15:17:45 +0900 |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/src/osdep/nt/yunchan.h Mon Sep 14 15:17:45 2009 +0900 1.3 @@ -0,0 +1,86 @@ 1.4 +/* ======================================================================== 1.5 + * Copyright 1988-2006 University of Washington 1.6 + * 1.7 + * Licensed under the Apache License, Version 2.0 (the "License"); 1.8 + * you may not use this file except in compliance with the License. 1.9 + * You may obtain a copy of the License at 1.10 + * 1.11 + * http://www.apache.org/licenses/LICENSE-2.0 1.12 + * 1.13 + * 1.14 + * ======================================================================== 1.15 + */ 1.16 + 1.17 +/* 1.18 + * Program: Unix compatibility routines 1.19 + * 1.20 + * Author: Mark Crispin 1.21 + * Networks and Distributed Computing 1.22 + * Computing & Communications 1.23 + * University of Washington 1.24 + * Administration Building, AG-44 1.25 + * Seattle, WA 98195 1.26 + * Internet: MRC@CAC.Washington.EDU 1.27 + * 1.28 + * Date: 14 September 1996 1.29 + * Last Edited: 30 August 2006 1.30 + */ 1.31 + 1.32 + 1.33 +/* DEDICATION 1.34 + * 1.35 + * This file is dedicated to my dog, Unix, also known as Yun-chan and 1.36 + * Unix J. Terwilliker Jehosophat Aloysius Monstrosity Animal Beast. Unix 1.37 + * passed away at the age of 11 1/2 on September 14, 1996, 12:18 PM PDT, after 1.38 + * a two-month bout with cirrhosis of the liver. 1.39 + * 1.40 + * He was a dear friend, and I miss him terribly. 1.41 + * 1.42 + * Lift a leg, Yunie. Luv ya forever!!!! 1.43 + */ 1.44 + 1.45 +/* For flock() emulation */ 1.46 + 1.47 +#define LOCK_SH 1 1.48 +#define LOCK_EX 2 1.49 +#define LOCK_NB 4 1.50 +#define LOCK_UN 8 1.51 + 1.52 + 1.53 +/* syslog() emulation */ 1.54 + 1.55 +#define LOG_MAIL (2<<3) /* mail system */ 1.56 +#define LOG_DAEMON (3<<3) /* system daemons */ 1.57 +#define LOG_AUTH (4<<3) /* security/authorization messages */ 1.58 +#define LOG_EMERG 0 /* system is unusable */ 1.59 +#define LOG_ALERT 1 /* action must be taken immediately */ 1.60 +#define LOG_CRIT 2 /* critical conditions */ 1.61 +#define LOG_ERR 3 /* error conditions */ 1.62 +#define LOG_WARNING 4 /* warning conditions */ 1.63 +#define LOG_NOTICE 5 /* normal but signification condition */ 1.64 +#define LOG_INFO 6 /* informational */ 1.65 +#define LOG_DEBUG 7 /* debug-level messages */ 1.66 +#define LOG_PID 0x01 /* log the pid with each message */ 1.67 +#define LOG_CONS 0x02 /* log on the console if errors in sending */ 1.68 +#define LOG_ODELAY 0x04 /* delay open until syslog() is called */ 1.69 +#define LOG_NDELAY 0x08 /* don't delay open */ 1.70 +#define LOG_NOWAIT 0x10 /* if forking to log on console, don't wait() */ 1.71 + 1.72 +#define tmpfile create_tempfile 1.73 +#define fclose close_file 1.74 +#define fsync _commit 1.75 +#define ftruncate chsize 1.76 +#define gethostid clock 1.77 +#define sleep(x) Sleep (1000 * x) 1.78 + 1.79 + 1.80 +long alarm (long seconds); 1.81 +int flock (int fd,int op); 1.82 +void openlog (const char *ident,int logopt,int facility); 1.83 +void syslog (int priority,const char *message,...); 1.84 +unsigned long unix_crlfcpy (char **dst,unsigned long *dstl,char *src, 1.85 + unsigned long srcl); 1.86 +unsigned long unix_crlflen (STRING *s); 1.87 +FILE *create_tempfile (void); 1.88 +int close_file (FILE *stream); 1.89 +char *getpass (const char *prompt);