Details | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
1 | daniel-mar | 1 | //--------------------------------------------------------------------------- |
2 | |||
3 | #ifndef ZipOpH |
||
4 | #define ZipOpH |
||
5 | /* |
||
6 | Copyright (c) 1990-2007 Info-ZIP. All rights reserved. |
||
7 | |||
8 | See the accompanying file LICENSE, version 2007-Mar-4 or later |
||
9 | (the contents of which are also included in zip.h) for terms of use. |
||
10 | If, for some reason, all these files are missing, the Info-ZIP license |
||
11 | also may be found at: ftp://ftp.info-zip.org/pub/infozip/license.html |
||
12 | |||
13 | parts Copyright (C) 1997 Mike White, Eric W. Engler |
||
14 | ************************************************************************ |
||
15 | Copyright (C) 2009, 2010 by Russell J. Peters, Roger Aelbrecht |
||
16 | |||
17 | This file is part of TZipMaster Version 1.9. |
||
18 | |||
19 | TZipMaster is free software: you can redistribute it and/or modify |
||
20 | it under the terms of the GNU Lesser General Public License as published by |
||
21 | the Free Software Foundation, either version 3 of the License, or |
||
22 | (at your option) any later version. |
||
23 | |||
24 | TZipMaster is distributed in the hope that it will be useful, |
||
25 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
||
26 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
||
27 | GNU Lesser General Public License for more details. |
||
28 | |||
29 | You should have received a copy of the GNU Lesser General Public License |
||
30 | along with TZipMaster. If not, see <http://www.gnu.org/licenses/>. |
||
31 | |||
32 | contact: problems@delphizip.org (include ZipMaster in the subject). |
||
33 | updates: http://www.delphizip.org |
||
34 | DelphiZip maillist subscribe at http://www.freelists.org/list/delphizip |
||
35 | ************************************************************************ |
||
36 | */ |
||
37 | |||
38 | #include "common.h" |
||
39 | #include "dzoper.h" |
||
40 | #include "DZRaw.h" |
||
41 | #include "ZipDflt.h" |
||
42 | #include "ZipFnc.h" |
||
43 | |||
44 | #define A_RONLY 0x01 |
||
45 | #define A_HIDDEN 0x02 |
||
46 | #define A_SYSTEM 0x04 |
||
47 | #define A_LABEL 0x08 |
||
48 | #define A_DIR 0x10 |
||
49 | #define A_ARCHIVE 0x20 |
||
50 | |||
51 | /* Forget FILENAME_MAX (incorrectly = 14 on some System V) */ |
||
52 | //#define FNMAX 256 |
||
53 | |||
54 | /* Lengths of headers after signatures in bytes */ |
||
55 | //#define LOCHEAD 26 |
||
56 | //#define CENHEAD 42 |
||
57 | //#define ENDHEAD 18 |
||
58 | |||
59 | #include "Crypt.h" |
||
60 | |||
61 | #define ADD 1 |
||
62 | |||
63 | class ZipOp : public ZipFunc |
||
64 | { |
||
65 | |||
66 | private: |
||
67 | ZipOp(const ZipOp&); |
||
68 | ZipOp& operator=(const ZipOp&); |
||
69 | |||
70 | protected: |
||
71 | long fOCDlength; |
||
72 | int fOldFAT; // ** |
||
73 | TCHAR fDrv[2]; // ** |
||
74 | int fnoisy; |
||
75 | int fvolume_label; |
||
76 | int ffix; |
||
77 | |||
78 | public: |
||
79 | int fhidden_files; |
||
80 | ZipOp(const DllCommands *C); |
||
81 | ~ZipOp(void); |
||
82 | long Exec(const DllCommands *C); |
||
83 | int readzipfile(void); |
||
84 | |||
85 | protected: |
||
86 | int ZipSelect(const DllCommands *C); |
||
87 | DZStrW ziptyp(const DZStrW &name); |
||
88 | int GetFileMode(const DZStrW &name); |
||
89 | |||
90 | int IsFileSystemOldFAT(const DZStrW &dir); |
||
91 | |||
92 | DZStrW getVolumeLabel(const DZStrW &drv, ulg *vtime, ulg *vmode, time_t *vutim); |
||
93 | // DZStrW ex2IntForm(const DZStrW &xname, bool ignore); // convert external to internal form |
||
94 | int ZipStreamStream(void); |
||
95 | |||
96 | private: |
||
97 | int ZipSetParam(const DllCommands *C); |
||
98 | void GiveGlobals(void); |
||
99 | int GetUserPW(void); // ZipSel |
||
100 | int MakeSpecials(void); //ZipSel |
||
101 | // DZStrW MakeExclFilters(void); |
||
102 | // DZStrW ConvExclFilters(const DZStrW & filters); |
||
103 | int Wild(const DZStrW &spec); |
||
104 | int procname(const DZStrW &fname, bool); |
||
105 | int newname(const DZStrW &n, ZInt64 nSize); |
||
106 | int readzipfile1(HANDLE hInz); |
||
107 | }; |
||
108 | |||
109 | int ZEN_Rank(int err); |
||
110 | |||
111 | //ZGlobals; /* end of struct ZGlobals */ |
||
112 | int issymlnk(ulg a); |
||
113 | |||
114 | #endif |
||
115 | |||
116 | |||
117 | |||
118 | |||
119 |