home *** CD-ROM | disk | FTP | other *** search
/ MacFormat 1996 Christmas / macformat-045.iso / Shareware Plus / Developers / enteract-377 / enteract-377.sit / EnterAct Stuff / hAWK project / AWK Source / hAWK_time.c < prev    next >
MacBinary  |  1994-12-22  |  2.0 KB  |  [TEXT/KEEN]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
66% dexvert Compact Compressed (Unix) (archive/compact) ext Supported
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Thu Dec 22 21:27:56 1994, modified Thu Dec 22 21:27:56 1994, creator 'KEEN', type ASCII, 1247 bytes "hAWK_time.c" , at 0x55f 532 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[KEEN]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0b 68 41 57 4b 5f 74 | 69 6d 65 2e 63 00 00 00 |..hAWK_t|ime.c...|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 4b 45 45 | 4e 01 00 00 00 00 00 00 |.TEXTKEE|N.......|
|00000050| 00 00 00 00 00 04 df 00 | 00 02 14 ab 1f e6 2c ab |........|......,.|
|00000060| 1f e6 2c 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..,.....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 4d b4 00 00 |........|....M...|
|00000080| 2f 2a 20 68 41 57 4b 5f | 74 69 6d 65 2e 63 20 3a |/* hAWK_|time.c :|
|00000090| 20 74 68 65 20 74 69 6d | 65 28 29 20 66 75 6e 63 | the tim|e() func|
|000000a0| 74 69 6f 6e 20 2a 2f 0d | 2f 2a 20 43 6f 70 79 72 |tion */.|/* Copyr|
|000000b0| 69 67 68 74 20 a9 20 31 | 39 38 36 2c 20 31 39 38 |ight . 1|986, 198|
|000000c0| 38 2c 20 31 39 38 39 20 | 31 39 39 31 20 74 68 65 |8, 1989 |1991 the|
|000000d0| 20 46 72 65 65 20 53 6f | 66 74 77 61 72 65 20 46 | Free So|ftware F|
|000000e0| 6f 75 6e 64 61 74 69 6f | 6e 2c 20 49 6e 63 2e 0d |oundatio|n, Inc..|
|000000f0| 20 2a 20 09 09 54 68 69 | 73 20 66 69 6c 65 20 69 | * ..Thi|s file i|
|00000100| 73 20 70 61 72 74 20 6f | 66 20 47 41 57 4b 2c 20 |s part o|f GAWK, |
|00000110| 74 68 65 20 47 4e 55 20 | 69 6d 70 6c 65 6d 65 6e |the GNU |implemen|
|00000120| 74 61 74 69 6f 6e 20 6f | 66 20 74 68 65 0d 20 2a |tation o|f the. *|
|00000130| 20 41 57 4b 20 50 72 6f | 67 61 6d 6d 69 6e 67 20 | AWK Pro|gamming |
|00000140| 4c 61 6e 67 75 61 67 65 | 2c 20 6d 6f 64 69 66 69 |Language|, modifi|
|00000150| 65 64 20 66 6f 72 20 74 | 68 65 20 4d 61 63 69 6e |ed for t|he Macin|
|00000160| 74 6f 73 68 20 28 61 6c | 73 6f 20 63 61 6c 6c 65 |tosh (al|so calle|
|00000170| 64 20 68 41 57 4b 29 2e | 0d 20 2a 20 09 09 47 41 |d hAWK).|. * ..GA|
|00000180| 57 4b 20 69 73 20 66 72 | 65 65 20 73 6f 66 74 77 |WK is fr|ee softw|
|00000190| 61 72 65 3b 20 79 6f 75 | 20 63 61 6e 20 72 65 64 |are; you| can red|
|000001a0| 69 73 74 72 69 62 75 74 | 65 20 6f 72 20 6d 6f 64 |istribut|e or mod|
|000001b0| 69 66 79 0d 20 2a 20 69 | 74 20 75 6e 64 65 72 20 |ify. * i|t under |
|000001c0| 74 68 65 20 74 65 72 6d | 73 20 6f 66 20 74 68 65 |the term|s of the|
|000001d0| 20 47 4e 55 20 47 65 6e | 65 72 61 6c 20 50 75 62 | GNU Gen|eral Pub|
|000001e0| 6c 69 63 20 4c 69 63 65 | 6e 73 65 20 61 73 20 70 |lic Lice|nse as p|
|000001f0| 75 62 6c 69 73 68 65 64 | 20 62 79 0d 20 2a 20 74 |ublished| by. * t|
|00000200| 68 65 20 46 72 65 65 20 | 53 6f 66 74 77 61 72 65 |he Free |Software|
|00000210| 20 46 6f 75 6e 64 61 74 | 69 6f 6e 3b 20 65 69 74 | Foundat|ion; eit|
|00000220| 68 65 72 20 76 65 72 73 | 69 6f 6e 20 31 2c 20 6f |her vers|ion 1, o|
|00000230| 72 20 61 6e 79 20 6c 61 | 74 65 72 20 76 65 72 73 |r any la|ter vers|
|00000240| 69 6f 6e 2e 0d 20 2a 20 | 09 09 47 41 57 4b 20 69 |ion.. * |..GAWK i|
|00000250| 73 20 64 69 73 74 72 69 | 62 75 74 65 64 20 69 6e |s distri|buted in|
|00000260| 20 74 68 65 20 68 6f 70 | 65 20 74 68 61 74 20 69 | the hop|e that i|
|00000270| 74 20 77 69 6c 6c 20 62 | 65 20 75 73 65 66 75 6c |t will b|e useful|
|00000280| 2c 0d 20 2a 20 62 75 74 | 20 57 49 54 48 4f 55 54 |,. * but| WITHOUT|
|00000290| 20 41 4e 59 20 57 41 52 | 52 41 4e 54 59 3b 20 77 | ANY WAR|RANTY; w|
|000002a0| 69 74 68 6f 75 74 20 65 | 76 65 6e 20 74 68 65 20 |ithout e|ven the |
|000002b0| 69 6d 70 6c 69 65 64 20 | 77 61 72 72 61 6e 74 79 |implied |warranty|
|000002c0| 20 6f 66 0d 20 2a 20 4d | 45 52 43 48 41 4e 54 41 | of. * M|ERCHANTA|
|000002d0| 42 49 4c 49 54 59 20 6f | 72 20 46 49 54 4e 45 53 |BILITY o|r FITNES|
|000002e0| 53 20 46 4f 52 20 41 20 | 50 41 52 54 49 43 55 4c |S FOR A |PARTICUL|
|000002f0| 41 52 20 50 55 52 50 4f | 53 45 2e 20 53 65 65 20 |AR PURPO|SE. See |
|00000300| 74 68 65 0d 20 2a 20 47 | 4e 55 20 47 65 6e 65 72 |the. * G|NU Gener|
|00000310| 61 6c 20 50 75 62 6c 69 | 63 20 4c 69 63 65 6e 73 |al Publi|c Licens|
|00000320| 65 20 66 6f 72 20 6d 6f | 72 65 20 64 65 74 61 69 |e for mo|re detai|
|00000330| 6c 73 2e 0d 20 2a 20 09 | 09 59 6f 75 20 73 68 6f |ls.. * .|.You sho|
|00000340| 75 6c 64 20 68 61 76 65 | 20 72 65 63 65 69 76 65 |uld have| receive|
|00000350| 64 20 61 20 63 6f 70 79 | 20 6f 66 20 74 68 65 20 |d a copy| of the |
|00000360| 47 4e 55 20 47 65 6e 65 | 72 61 6c 20 50 75 62 6c |GNU Gene|ral Publ|
|00000370| 69 63 20 4c 69 63 65 6e | 73 65 0d 20 2a 20 61 6c |ic Licen|se. * al|
|00000380| 6f 6e 67 20 77 69 74 68 | 20 47 41 57 4b 3b 20 73 |ong with| GAWK; s|
|00000390| 65 65 20 74 68 65 20 66 | 69 6c 65 20 22 43 4f 50 |ee the f|ile "COP|
|000003a0| 59 49 4e 47 20 68 41 57 | 4b 22 2e 20 49 66 20 6e |YING hAW|K". If n|
|000003b0| 6f 74 2c 20 77 72 69 74 | 65 20 74 6f 0d 20 2a 20 |ot, writ|e to. * |
|000003c0| 74 68 65 20 46 72 65 65 | 20 53 6f 66 74 77 61 72 |the Free| Softwar|
|000003d0| 65 20 46 6f 75 6e 64 61 | 74 69 6f 6e 2c 20 36 37 |e Founda|tion, 67|
|000003e0| 35 20 4d 61 73 73 20 41 | 76 65 2c 20 43 61 6d 62 |5 Mass A|ve, Camb|
|000003f0| 72 69 64 67 65 2c 20 4d | 41 20 30 32 31 33 39 2c |ridge, M|A 02139,|
|00000400| 20 55 53 41 2e 0d 20 2a | 20 57 72 69 74 74 65 6e | USA.. *| Written|
|00000410| 20 66 6f 72 20 54 48 49 | 4e 4b 20 43 20 34 20 6f | for THI|NK C 4 o|
|00000420| 6e 20 74 68 65 20 4d 61 | 63 69 6e 74 6f 73 68 20 |n the Ma|cintosh |
|00000430| 62 79 20 4b 65 6e 20 45 | 61 72 6c 65 20 28 44 79 |by Ken E|arle (Dy|
|00000440| 6e 61 62 79 74 65 29 20 | 41 75 67 20 31 39 39 31 |nabyte) |Aug 1991|
|00000450| 2e 0d 20 2a 2f 0d 23 69 | 6e 63 6c 75 64 65 20 22 |.. */.#i|nclude "|
|00000460| 41 57 4b 2e 48 22 0d 0d | 4e 4f 44 45 20 2a 64 6f |AWK.H"..|NODE *do|
|00000470| 5f 74 69 6d 65 28 4e 4f | 44 45 20 2a 74 72 65 65 |_time(NO|DE *tree|
|00000480| 29 3b 0d 0d 4e 4f 44 45 | 20 2a 64 6f 5f 74 69 6d |);..NODE| *do_tim|
|00000490| 65 28 4e 4f 44 45 20 2a | 74 72 65 65 29 0d 09 7b |e(NODE *|tree)..{|
|000004a0| 0d 09 74 69 6d 65 5f 74 | 09 09 6e 6f 77 3b 0d 09 |..time_t|..now;..|
|000004b0| 73 74 72 75 63 74 20 74 | 6d 09 2a 64 61 74 65 3b |struct t|m.*date;|
|000004c0| 0d 09 63 68 61 72 09 09 | 73 5b 38 30 5d 3b 0d 09 |..char..|s[80];..|
|000004d0| 73 68 6f 72 74 20 09 09 | 69 3b 0d 09 0d 09 6e 6f |short ..|i;....no|
|000004e0| 77 20 3d 20 74 69 6d 65 | 28 4e 55 4c 4c 29 3b 0d |w = time|(NULL);.|
|000004f0| 09 64 61 74 65 20 3d 20 | 6c 6f 63 61 6c 74 69 6d |.date = |localtim|
|00000500| 65 28 26 6e 6f 77 29 3b | 0d 09 69 20 3d 20 73 74 |e(&now);|..i = st|
|00000510| 72 66 74 69 6d 65 28 73 | 2c 38 30 2c 20 22 25 41 |rftime(s|,80, "%A|
|00000520| 2c 20 25 42 20 25 64 2c | 20 25 59 20 25 49 3a 25 |, %B %d,| %Y %I:%|
|00000530| 4d 3a 25 53 20 25 70 22 | 2c 20 64 61 74 65 29 3b |M:%S %p"|, date);|
|00000540| 0d 09 72 65 74 75 72 6e | 28 74 6d 70 5f 73 74 72 |..return|(tmp_str|
|00000550| 69 6e 67 28 73 2c 20 69 | 29 29 3b 0d 09 7d 0d 00 |ing(s, i|));..}..|
|00000560| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000570| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000580| 00 00 01 00 00 00 01 7e | 00 00 00 7e 00 00 00 96 |.......~|...~....|
|00000590| 00 00 84 00 da 00 96 01 | 20 04 04 53 61 76 65 00 |........| ..Save.|
|000005a0| 00 00 00 00 9e 00 da 00 | b0 01 20 04 06 43 61 6e |........|.. ..Can|
|000005b0| 0b 68 41 57 4b 5f 74 69 | 6d 65 2e 63 02 00 00 00 |.hAWK_ti|me.c....|
|000005c0| 54 45 58 54 4b 45 45 4e | 01 00 00 5e 00 9c 00 00 |TEXTKEEN|...^....|
|000005d0| 00 00 54 45 58 54 4b 45 | 45 4e 01 00 00 5e 00 9c |..TEXTKE|EN...^..|
|000005e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000005f0| 00 00 a5 30 2b 80 00 00 | 04 df 00 00 02 14 00 00 |...0+...|........|
|00000600| 00 00 00 00 9d 00 11 00 | ad 00 c2 10 00 00 00 00 |........|........|
|00000610| 00 00 1d 00 0e 00 7f 00 | c5 80 00 00 00 00 30 00 |........|......0.|
|00000620| 01 00 00 00 00 00 32 00 | 70 00 44 00 ba 04 02 4f |......2.|p.D....O|
|00000630| 4b 00 00 00 00 00 0e 00 | 10 00 2e 00 ba 88 0f 44 |K.......|.......D|
|00000640| 69 73 6b 20 69 73 20 6c | 6f 63 6b 65 64 2e 00 00 |isk is l|ocked...|
|00000650| 00 00 4a 00 02 00 00 00 | 00 00 32 00 70 00 44 00 |..J.....|..2.p.D.|
|00000660| ba 04 02 4e 6f 00 00 00 | 00 00 32 00 10 00 44 00 |...No...|..2...D.|
|00000670| 5a 04 03 59 65 73 00 00 | 00 00 00 00 0e 00 10 00 |Z..Yes..|........|
|00000680| 00 00 00 04 00 06 00 04 | 00 00 00 0a 00 09 06 4d |........|.......M|
|00000690| 6f 6e 61 63 6f 00 00 00 | 00 04 ab 1f 9f dc 00 00 |onaco...|........|
|000006a0| 00 08 00 41 00 14 01 35 | 01 f0 00 00 00 48 00 09 |...A...5|.....H..|
|000006b0| 4d 6f 6e 61 63 6f 00 00 | 00 00 00 00 00 00 00 00 |Monaco..|........|
|000006c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000006d0| 00 03 00 04 00 57 00 0a | 01 f1 02 80 00 57 00 0a |.....W..|.....W..|
|000006e0| 01 f1 02 80 ac 4d 72 40 | 00 00 03 95 00 00 03 9a |.....Mr@|........|
|000006f0| 00 00 00 00 01 00 00 00 | 00 04 00 01 00 01 00 00 |........|........|
|00000700| 01 00 00 00 01 7e 00 00 | 00 7e 00 00 00 96 00 cd |.....~..|.~......|
|00000710| 4d 88 13 1a 00 00 00 1c | 00 96 00 05 45 54 41 42 |M.......|....ETAB|
|00000720| 00 00 00 32 45 46 4e 54 | 00 00 00 3e 4a 41 47 5a |...2EFNT|...>JAGZ|
|00000730| 00 00 00 4a 57 53 49 5a | 00 00 00 56 4d 50 53 52 |...JWSIZ|...VMPSR|
|00000740| 00 00 00 62 4d 57 42 42 | 00 00 00 6e 03 ec ff ff |...bMWBB|...n....|
|00000750| 00 00 00 00 00 00 00 00 | 03 eb ff ff 00 00 00 08 |........|........|
|00000760| 00 00 00 00 03 ed ff ff | 00 00 00 16 00 00 00 00 |........|........|
|00000770| 03 ee ff ff 00 00 00 1e | 00 00 00 00 03 ed ff ff |........|........|
|00000780| 00 00 00 2a 00 00 00 00 | 03 f0 ff ff 00 00 00 76 |...*....|.......v|
|00000790| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007a0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007b0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007c0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007d0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007e0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|000007f0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+