File: embperl.h

package info (click to toggle)
libhtml-embperl-perl 1.3.6-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 2,596 kB
  • ctags: 1,190
  • sloc: ansic: 8,985; perl: 4,584; makefile: 83
file content (211 lines) | stat: -rw-r--r-- 5,136 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
/*###################################################################################
#
#   Embperl - Copyright (c) 1997-2001 Gerald Richter / ECOS
#
#   You may distribute under the terms of either the GNU General Public
#   License or the Artistic License, as specified in the Perl README file.
#   For use with Apache httpd and mod_perl, see also Apache copyright.
#
#   THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT ANY EXPRESS OR
#   IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
#   WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
#   $Id: embperl.h,v 1.29 2001/11/02 10:03:48 richter Exp $
#
###################################################################################*/



/*
    Errors and Return Codes
*/

enum tRc
    {
    ok = 0,
    rcStackOverflow,
    rcStackUnderflow,
    rcEndifWithoutIf,
    rcElseWithoutIf,
    rcEndwhileWithoutWhile,
    rcEndtableWithoutTable,
    rcCmdNotFound,
    rcOutOfMemory,
    rcPerlVarError,
    rcHashError,
    rcArrayError,
    rcFileOpenErr,    
    rcMissingRight,
    rcNoRetFifo,
    rcMagicError,
    rcWriteErr,
    rcUnknownNameSpace,
    rcInputNotSupported,
    rcCannotUsedRecursive,
    rcEndtableWithoutTablerow,
    rcTablerowOutsideOfTable, 
    rcEndtextareaWithoutTextarea,
    rcArgStackOverflow,
    rcEvalErr,
    rcNotCompiledForModPerl,
    rcLogFileOpenErr,
    rcExecCGIMissing,
    rcIsDir,
    rcXNotSet,
    rcNotFound,
    rcUnknownVarType,
    rcPerlWarn,
    rcVirtLogNotSet,
    rcMissingInput,
    rcExit,
    rcUntilWithoutDo, 
    rcEndforeachWithoutForeach, 
    rcMissingArgs,
    rcNotAnArray,
    rcCallInputFuncFailed,
    rcCallOutputFuncFailed,
    rcSubNotFound,
    rcImportStashErr,
    rcCGIError,
    rcUnclosedHtml,
    rcUnclosedCmd,
    rcNotAllowed,
    rcNotHashRef,
    rcTagMismatch,
    rcCleanupErr,
    rcCryptoWrongHeader,
    rcCryptoWrongSyntax,
    rcCryptoNotSupported,
    rcCryptoBufferOverflow,
    rcCryptoErr
    } ;


/*
    Debug Flags
*/

enum dbg
    {
    dbgStd          = 1,
    dbgMem          = 2,
    dbgEval         = 4,
    dbgCmd          = 8,
    dbgEnv          = 16,
    dbgForm         = 32,
    dbgTab          = 64,
    dbgInput        = 128,
    dbgFlushOutput  = 256,
    dbgFlushLog     = 512,
    dbgAllCmds      = 1024,
    dbgSource       = 2048,
    dbgFunc         = 4096,
    dbgLogLink      = 8192,
    dbgDefEval      = 16384,
    dbgOutput           = 0x08000,
    dbgDOM              = 0x10000,
    dbgRun              = 0x20000,
    dbgHeadersIn        = 0x40000,
    dbgShowCleanup      = 0x80000,
    dbgProfile          = 0x100000,
    dbgSession          = 0x200000,
    dbgImport		= 0x400000,
    dbgBuildToken       = 0x800000,
    dbgParse            = 0x1000000,
    dbgObjectSearch     = 0x2000000,
    dbgCache            = 0x4000000,
    dbgCompile          = 0x8000000,
    dbgXML              = 0x10000000,
    dbgXSLT             = 0x20000000,
    dbgCheckpoint       = 0x40000000,
    
    dbgAll  = -1
    } ;

/*
    Option Flags
*/

enum opt
    {
    optDisableVarCleanup       = 1,
    optDisableEmbperlErrorPage = 2,
    optSafeNamespace           = 4,
    optOpcodeMask              = 8,
    optRawInput                = 16,
    optSendHttpHeader          = 32,
    optEarlyHttpHeader         = 64,
    optDisableChdir            = 128,
    optDisableFormData         = 256,
    optDisableHtmlScan         = 512,
    optDisableInputScan        = 1024,
    optDisableTableScan        = 2048,
    optDisableMetaScan         = 4096,
    optAllFormData             = 8192,
    optRedirectStdout          = 16384,
    optUndefToEmptyValue       = 32768,
    optNoHiddenEmptyValue      = 65536,
    optAllowZeroFilesize       = 0x20000, 
    optReturnError             = 0x40000, 
    optKeepSrcInMemory         = 0x80000,
    optKeepSpaces	       = 0x100000,
    optOpenLogEarly            = 0x200000,
    optNoUncloseWarn	       = 0x400000,
    optDisableSelectScan       = 0x800000,
    optAddUserSessionToLinks   = 0x1000000,
    optAddStateSessionToLinks  = 0x2000000,
    optNoSessionCookies        = 0x4000000,
    optShowBacktrace           = 0x8000000
    } ;

/*
    I/O modes
*/

enum epIO
    {
    epIOCGI      = 1,
    epIOProcess  = 2,
    epIOMod_Perl = 3,
    epIOPerl     = 4
    } ;
    
/*
    Table modes
*/

#define epTabRow        0x0f   /* Row Mask */
#define epTabRowDef     0x01   /* Last row where last defined expression */
#define epTabRowUndef   0x02   /* Last row where first undefined expression */
#define epTabRowMax     0x03   /* maxrow determinates number of rows */

#define epTabCol        0xf0   /* Column Mask */
#define epTabColDef     0x10   /* Last column where last defined expression */
#define epTabColUndef   0x20   /* Last column where first undefined expression */
#define epTabColMax     0x30   /* maxcol determinates number of columns */





/*
    Escape modes
*/


enum tEscMode
    {
    escNone = 0,
    escHtml = 1,
    escUrl  = 2,
    escStd  = 3,
    escEscape  = 4
    } ;


#if !defined (pid_t) && defined (WIN32)
#define pid_t int
#endif

extern pid_t nPid ;