/[LeafOK_CVS]/innwebd/logfile.cpp
ViewVC logotype

Contents of /innwebd/logfile.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations)
Sat Feb 26 16:10:26 2005 UTC (21 years ago) by sysadm
Branch: MAIN
CVS Tags: innwebd_1-4-16-0_MIL
Changes since 1.3: +1 -1 lines
Content type: text/x-c++src
Copyright update

1 /*******************************************************/
2 /* */
3 /* LeafOK Innbbsd */
4 /* Copyright (C) LeafOK.com, 2003-2005 */
5 /* */
6 /* Programmed by Leaf */
7 /* E-mail:leaflet@leafok.com QQ:6049044 */
8 /* */
9 /* http://bbs.leafok.com */
10 /* http://bbs.leafok.net */
11 /* http://bbs.fenglin.info */
12 /* */
13 /*******************************************************/
14
15 #include "StdAfx.h"
16 #include ".\logfile.h"
17
18 logfile::logfile(void)
19 {
20 }
21
22 logfile::~logfile(void)
23 {
24 }
25
26 logfile& logfile::log_head(logfile& logfile)
27 {
28 struct tm *newtime;
29 __int64 ltime;
30 char s_time[256];
31
32 _time64( &ltime );
33 newtime = _localtime64( &ltime );
34 strftime(s_time,255,"%d/%b/%Y %H:%M:%S",newtime);
35
36 logfile << "[" << s_time << "] [" << GetCurrentThreadId() << "] ";
37
38 return logfile;
39 }
40
41 logfile& logfile::operator<<(logfile& fun(logfile&))
42 {
43 fun(*this);
44 return (*this);
45 }

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1