richter 01/05/15 07:21:40
Modified: . Tag: Embperl2c Changes.pod Embperl.xs
EmbperlObject.pm INSTALL.pod MANIFEST MANIFEST.2
Makefile.PL README README.v2 epcmd2.c epcomp.c
epdom.c epdom.h epeval.c epmain.c epnames.h
epparse.c eputil.c test.pl
Embperl/Syntax Tag: Embperl2c SSI.pm
test/conf Tag: Embperl2c httpd.conf.src
test/html/rawinput Tag: Embperl2c include.htm
test/html/registry Tag: Embperl2c tied.htm
Log:
Embperl - fix memory leak
Revision Changes Path
No revision
No revision
1.129.4.22 +3 -0 embperl/Changes.pod
Index: Changes.pod
===================================================================
RCS file: /home/cvs/embperl/Changes.pod,v
retrieving revision 1.129.4.21
retrieving revision 1.129.4.22
diff -u -r1.129.4.21 -r1.129.4.22
--- Changes.pod 2001/05/11 07:13:33 1.129.4.21
+++ Changes.pod 2001/05/15 14:19:19 1.129.4.22
@@ -132,6 +132,9 @@
(e.g. perldoc HTML::Embperl::Intro works now after installation). Based
on an idea from Angus Lees.
- Makefile.PL enhancements for Apache/ActiveState binary distribution
+ - quote pathnames in Makefile to allow directories like "Program Files".
+ Spotted by Lukas Zapletal.
+ - Added epocgi.pl which allow use of EmbperlObject as CGI script.
=head1 1.3.1 (RELEASE) 13 Feb. 2001
1.29.4.16 +4 -3 embperl/Embperl.xs
Index: Embperl.xs
===================================================================
RCS file: /home/cvs/embperl/Embperl.xs,v
retrieving revision 1.29.4.15
retrieving revision 1.29.4.16
diff -u -r1.29.4.15 -r1.29.4.16
--- Embperl.xs 2001/05/11 07:13:38 1.29.4.15
+++ Embperl.xs 2001/05/15 14:19:23 1.29.4.16
@@ -745,10 +745,11 @@
if (items > 1)
{
r -> pCodeSV = ST(1) ;
- SvREFCNT_inc (ST(1)) ;
+ SvREFCNT_inc (r -> pCodeSV) ;
}
-OUTPUT:
- RETVAL
+ ST(0) = RETVAL;
+ if (RETVAL != &sv_undef)
+ sv_2mortal(ST(0));
1.36.4.5 +8 -2 embperl/EmbperlObject.pm
Index: EmbperlObject.pm
===================================================================
RCS file: /home/cvs/embperl/EmbperlObject.pm,v
retrieving revision 1.36.4.4
retrieving revision 1.36.4.5
diff -u -r1.36.4.4 -r1.36.4.5
--- EmbperlObject.pm 2001/03/27 11:51:58 1.36.4.4
+++ EmbperlObject.pm 2001/05/15 14:19:25 1.36.4.5
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: EmbperlObject.pm,v 1.36.4.4 2001/03/27 11:51:58 richter Exp $
+# $Id: EmbperlObject.pm,v 1.36.4.5 2001/05/15 14:19:25 richter Exp $
#
###################################################################################
@@ -390,7 +390,13 @@
The runtime configuration is done by setting environment variables,
in your web
-server's configuration file.
+server's configuration file. Basicly the configuration is the same as
+for normal Embperl. All Embperl configuration directives also applies
+to EmbperlObject. There are a few addtional configuration directives
+listed below. Addtionaly you have to set the C<PerlHandler> to
+C<HTML::EmbperlObject> when running under mod_perl or use C<epocgi.pl>
+instead of C<embpcgi.pl> when running as CGI Script.
+
=head2 EMBPERL_DECLINE
1.12.4.5 +76 -11 embperl/INSTALL.pod
Index: INSTALL.pod
===================================================================
RCS file: /home/cvs/embperl/INSTALL.pod,v
retrieving revision 1.12.4.4
retrieving revision 1.12.4.5
diff -u -r1.12.4.4 -r1.12.4.5
--- INSTALL.pod 2001/05/11 07:13:40 1.12.4.4
+++ INSTALL.pod 2001/05/15 14:19:29 1.12.4.5
@@ -61,7 +61,7 @@
=head2 Options for make test
-C<make test> can take several options, with can be given with the C<TESTARGS>
+C<make test> can take several options, which can be given with the C<TESTARGS>
parameter:
make test TESTARGS="--help"
@@ -104,18 +104,38 @@
a DSO mod-perl (ie: apache + libapache-mod-perl) for now.
-=head2 WIN 32
+=head2 UNIX (without Apache Source)
-I have tested the offline mode on Windows 95 with a Microsoft Visual C++ 4.2
-compiler and I have succesfully run Embperl with apache_1.3b5-1.3.9 /
-mod_perl-1.12-1.21 / perl5.004_04-perl5.005 (without threads) on Windows NT
-with VC++ 5.0.
-
-B<NOTE:> It was necessary for me to compile perl5.004_04 with the VC++ on my own
-to get it to run with Apache and mod_perl, while I was able to use the binary
-distribution (/authors/id/GSAR/perl5.00402-bindist04-bc.tar.gz) of Perl for
-offline testing under Win 95.
+If you have an UNIX with preinstalled Apache and mod_perl (e.g. a Linux
+distribution), you need to locate the following files on your disk:
+ - httpd.h
+ - httpd
+ - mod_env.so
+
+For example in SuSE Linux 7.1 they could be found at
+
+ - /usr/include/apache/httpd.h
+ - /usr/sbin/httpd
+ - /usr/lib/apache/mod_env.so
+
+Now go to the Embperl directory and start
+
+ perl Makefile.PL
+
+When get asked for the Apache sources, enter the directory where you
+found C<httpd.h> (e.g. C</usr/include/apache>). For the Apache executable
+enter the path to C<httpd>. If the Apache modules are loaded dynamicly,
+the you will get ask for C<mod_env.so>, enter it's directory. Now you can
+continue as normal with
+
+ make test
+ make install
+
+
+=head2 WIN 32 (non ActiveState Perl)
+
+
B<NOTE:> You need mod_perl >= 1.12 on win32
@@ -179,6 +199,51 @@
If you have already successfully build and tested C<mod_perl> all modules
will already be there.
+
+=head2 WIN 32 with ActiveState Perl
+
+First get and install ActiveState Perl from http://www.activestate.com
+
+You can skip the installation of Apache and mod_perl, if you only want
+to use Embperl offline or as CGI.
+
+Next get the Apache binary (including the source e.g.
apache_1.3.19-win32-src-r2.msi) from
+http://www.apache.org/dist/httpd/binaries/win32/ . (You may need to install the
+windows MSI installer from the same page too). Now run the installation.
+
+Then run the ppm program to install mod_perl
+
+ ppm install http://theoryx5.uwinnipeg.ca/ppmpackages/mod_perl-1.25_1.3.19.ppd
+
+If you get asked for the Apache directory, enter the C<modules> subdirectory under
the path
+where you have installed your Apache, e.g.
+
+ \Program Files\Apache Group\Apache\modules
+
+As last step you can install the Embperl ppd:
+
+ ppm install http://theoryx5.uwinnipeg.ca/ppmpackages/HTML-Embperl.ppd
+
+
+=head2 Compile Embperl from the sources on WIN 32 with ActiveState Perl
+
+First install ActiveState Perl, Apache and mod_perl as described above. Make sure
+you have an Apache version which includes the sources. (Of course when you want to
use
+Embperl only offline or as CGI you don't have to install Apache and mod_perl)
+
+Then extract the Embperl distribution and go to the directory where you have
extracted
+Embperl. Start
+
+ perl Makefile.PL
+
+Enter y or hit enter when you get ask "Build with support for Apache mod_perl?(y/n)
[y]"
+When get asked for the Apache source enter the Apache directory you have installed
above.
+e.g. \Program Files\Apache Group.
+
+Now you can continue by running
+
+ nmake test
+ nmake install
=head2 How to continue
1.50.4.25 +7 -3 embperl/MANIFEST
Index: MANIFEST
===================================================================
RCS file: /home/cvs/embperl/MANIFEST,v
retrieving revision 1.50.4.24
retrieving revision 1.50.4.25
diff -u -r1.50.4.24 -r1.50.4.25
--- MANIFEST 2001/05/11 07:13:43 1.50.4.24
+++ MANIFEST 2001/05/15 14:19:30 1.50.4.25
@@ -14,6 +14,7 @@
Embperl/Syntax/Text.pm
Embperl/Syntax/Perl.pm
Embperl/Syntax/Mail.pm
+Embperl/Syntax/RTF.pm
README.v2
test/cmp2/errdoc2.htm
test/cmp2/error.htm
@@ -57,9 +58,9 @@
test/html/execsecond.htm
test/html/execprint.htm
test/html/inputjs2.htm
-test/html/rtfbasic.asc
-test/html/rtffull.asc
-test/html/rtfloop.asc
+test/html/rtf/rtfbasic.asc
+test/html/rtf/rtffull.asc
+test/html/rtf/rtfloop.asc
test/cmp/incif.htm
test/cmp/executesub.htm
test/cmp/ssibasic.htm
@@ -120,6 +121,9 @@
embpcgi.pl.templ
embpcgi.bat.templ
embpcgi.test.pl.templ
+epocgi.pl.templ
+epocgi.bat.templ
+epocgi.test.pl.templ
ep.h
epdat.h
epio.c
1.1.2.17 +4 -3 embperl/Attic/MANIFEST.2
Index: MANIFEST.2
===================================================================
RCS file: /home/cvs/embperl/Attic/MANIFEST.2,v
retrieving revision 1.1.2.16
retrieving revision 1.1.2.17
diff -u -r1.1.2.16 -r1.1.2.17
--- MANIFEST.2 2001/05/08 12:55:43 1.1.2.16
+++ MANIFEST.2 2001/05/15 14:19:32 1.1.2.17
@@ -14,6 +14,7 @@
Embperl/Syntax/Text.pm
Embperl/Syntax/Perl.pm
Embperl/Syntax/Mail.pm
+Embperl/Syntax/RTF.pm
README.v2
test/cmp2/errdoc2.htm
test/cmp2/error.htm
@@ -57,9 +58,9 @@
test/html/execsecond.htm
test/html/execprint.htm
test/html/inputjs2.htm
-test/html/rtfbasic.asc
-test/html/rtffull.asc
-test/html/rtfloop.asc
+test/html/rtf/rtfbasic.asc
+test/html/rtf/rtffull.asc
+test/html/rtf/rtfloop.asc
test/cmp/incif.htm
test/cmp/executesub.htm
test/cmp/ssibase.htm
1.31.4.13 +10 -9 embperl/Makefile.PL
Index: Makefile.PL
===================================================================
RCS file: /home/cvs/embperl/Makefile.PL,v
retrieving revision 1.31.4.12
retrieving revision 1.31.4.13
diff -u -r1.31.4.12 -r1.31.4.13
--- Makefile.PL 2001/05/11 07:13:44 1.31.4.12
+++ Makefile.PL 2001/05/15 14:19:34 1.31.4.13
@@ -520,18 +520,18 @@
if ($win32)
{
- $i = "-I. -I$inc_dir -I$apache_src/regex -I$apache_src/os/win32" ;
+ $i = "-I. -I\"$inc_dir\" -I\"$apache_src/regex\"
-I\"$apache_src/os/win32\"" ;
if (-e "$apache_src/../libexec/ApacheCore.lib")
{
- $o = " $apache_src/../libexec/ApacheCore.lib" ;
+ $o = " \"$apache_src/../libexec/ApacheCore.lib\"" ;
}
elsif (!-e "$apache_src/CoreD/ApacheCore.lib")
{
- $o = " $apache_src/CoreR/ApacheCore.lib" ;
+ $o = " \"$apache_src/CoreR/ApacheCore.lib\"" ;
}
else
{
- $o = " $apache_src/CoreD/ApacheCore.lib" ;
+ $o = " \"$apache_src/CoreD/ApacheCore.lib\"" ;
}
}
else
@@ -644,7 +644,7 @@
### check the apache version ###
- $ENV{PATH} .= ";$EPHTTPDDLL" if ($win32) ;
+ $ENV{PATH} .= ";\"$EPHTTPDDLL\"" if ($win32) ;
@EPAPACHEVERSION = start ("$EPHTTPD -v") ;
@@ -677,7 +677,7 @@
#print "path = $_ -> $path\n" ;
if (-f $path)
{ ## module fould
- $EPMODPERL .= "\r\nLoadModule $opt->{name} $path" ;
+ $EPMODPERL .= "\r\nLoadModule $opt->{name} \"$path\"" ;
print " + Load dynamic module $mod\n ($path)\n" ;
$found = 1 ;
last ;
@@ -689,7 +689,7 @@
#print "path = $_ -> $path\n" ;
if (-f $path)
{ ## module fould
- $EPMODPERL .= "\r\nLoadModule $opt->{name} $path" ;
+ $EPMODPERL .= "\r\nLoadModule $opt->{name} \"$path\"" ;
print " + Load dynamic module $mod\n ($path)\n" ;
$found = 1 ;
last ;
@@ -702,7 +702,7 @@
$path = $1 ;
if (-f $path)
{ ## module fould
- $EPMODPERL .= "\r\nLoadModule $opt->{name} $path" ;
+ $EPMODPERL .= "\r\nLoadModule $opt->{name} \"$path\"" ;
print " + Load dynamic module $mod\n ($path)\n" ;
$found = 1 ;
last ;
@@ -971,7 +971,8 @@
#
@bins = ('embpexec.pl','embpexec.bat',
- 'embpcgi.pl', 'embpcgi.test.pl', 'embpcgi.bat') ;
+ 'embpcgi.pl', 'embpcgi.test.pl', 'embpcgi.bat',
+ 'epocgi.pl', 'epocgi.test.pl', 'epocgi.bat') ;
die "Missing path to perl binary" if (!$perlbinpath) ;
1.19.6.9 +4 -3 embperl/README
Index: README
===================================================================
RCS file: /home/cvs/embperl/README,v
retrieving revision 1.19.6.8
retrieving revision 1.19.6.9
diff -u -r1.19.6.8 -r1.19.6.9
--- README 2001/03/28 19:15:31 1.19.6.8
+++ README 2001/05/15 14:19:36 1.19.6.9
@@ -9,19 +9,20 @@
WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-$Id: README,v 1.19.6.8 2001/03/28 19:15:31 richter Exp $
+$Id: README,v 1.19.6.9 2001/05/15 14:19:36 richter Exp $
### !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !!
###
###
-### This is the second BETA release of Embperl 2.0, before installing
+### This is the third BETA release of Embperl 2.0, before installing
### please read the README.v2. Documentation is not yet updated to
### reflect the changes in 2.0, everything that has changed is
-### documented in README.v2. Since the first beta I have fixed a lot
+### documented in README.v2. Since the first and second beta I have fixed a lot
### of smaller bugs and use it now in production environment on my own.
### But be carefull this release may still contain bugs.
###
+### The current stable release is Embperl 1.3.2
###
### !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !!
1.1.4.11 +6 -3 embperl/Attic/README.v2
Index: README.v2
===================================================================
RCS file: /home/cvs/embperl/Attic/README.v2,v
retrieving revision 1.1.4.10
retrieving revision 1.1.4.11
diff -u -r1.1.4.10 -r1.1.4.11
--- README.v2 2001/03/29 05:28:42 1.1.4.10
+++ README.v2 2001/05/15 14:19:39 1.1.4.11
@@ -9,19 +9,20 @@
WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-$Id: README.v2,v 1.1.4.10 2001/03/29 05:28:42 richter Exp $
+$Id: README.v2,v 1.1.4.11 2001/05/15 14:19:39 richter Exp $
### !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !!
###
###
-### This is the second BETA release of Embperl 2.0, before installing
+### This is the third BETA release of Embperl 2.0, before installing
### please read the README.v2. Documentation is not yet updated to
### reflect the changes in 2.0, everything that has changed is
-### documented in README.v2. Since the first beta I have fixed a lot
+### documented in README.v2. Since the first and second beta I have fixed a lot
### of smaller bugs and use it now in production environment on my own.
### But be carefull this release may still contain bugs.
###
+### The current stable release is Embperl 1.3.2
###
### !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !! IMPORTANT !!
@@ -145,6 +146,8 @@
- [- exit -]
- safe namespaces
+
+- print to OUT does not work correctly inside of loops
Embperl 1.x compatibility flag
1.4.2.9 +2 -3 embperl/Attic/epcmd2.c
Index: epcmd2.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epcmd2.c,v
retrieving revision 1.4.2.8
retrieving revision 1.4.2.9
diff -u -r1.4.2.8 -r1.4.2.9
--- epcmd2.c 2001/05/04 06:08:11 1.4.2.8
+++ epcmd2.c 2001/05/15 14:19:41 1.4.2.9
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epcmd2.c,v 1.4.2.8 2001/05/04 06:08:11 richter Exp $
+# $Id: epcmd2.c,v 1.4.2.9 2001/05/15 14:19:41 richter Exp $
#
###################################################################################*/
@@ -61,8 +61,7 @@
if (dlen == nValLen && strncmp (pVal, pData, dlen) == 0)
{
bEqual = 1 ;
- SvREFCNT_inc (pSV) ;
- hv_store (pCurrReq -> pInputHash, (char *)pName, nNameLen,
newSVsv(pSV), 0) ;
+ hv_store (pCurrReq -> pInputHash, (char *)pName, nNameLen,
newSVsv(pSV), 0) ;
}
}
1.4.2.52 +50 -115 embperl/Attic/epcomp.c
Index: epcomp.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epcomp.c,v
retrieving revision 1.4.2.51
retrieving revision 1.4.2.52
diff -u -r1.4.2.51 -r1.4.2.52
--- epcomp.c 2001/05/08 06:29:38 1.4.2.51
+++ epcomp.c 2001/05/15 14:19:43 1.4.2.52
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epcomp.c,v 1.4.2.51 2001/05/08 06:29:38 richter Exp $
+# $Id: epcomp.c,v 1.4.2.52 2001/05/15 14:19:43 richter Exp $
#
###################################################################################*/
@@ -933,7 +933,7 @@
r -> pCodeSV = newSVpv (pCode, nCodeLen) ;
}
else
- r -> pCodeSV = &sv_undef ;
+ r -> pCodeSV = &sv_undef ;
if ((rc = EvalDirect (r, pSV, 1, args)) != ok)
LogError (r, rc) ;
SvREFCNT_dec(pSV);
@@ -1048,10 +1048,10 @@
char buf [80] ;
pNode -> bFlags |= nflgCheckpoint ;
- //l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n",
*bCheckpointPending<0?pNode -> xNdx:*bCheckpointPending) ;
- //l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n", pNode -> xNdx) ;
+ /* l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n",
*bCheckpointPending<0?pNode -> xNdx:*bCheckpointPending) ; */
+ /* l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n", pNode -> xNdx) ; */
l = sprintf (buf, " _ep_cp(%d) ;\n", pNode -> xNdx) ;
- //l = sprintf (buf, " $_ep_cp=%d;\n", pNode -> xNdx) ;
+ /* l = sprintf (buf, " $_ep_cp=%d;\n", pNode -> xNdx) ; */
nCheckpointCodeOffset = StringAdd (r -> pProg, buf, l) ;
*bCheckpointPending = 0 ;
@@ -1231,8 +1231,8 @@
if (nNdx <= pInfo -> nMaxEmbperlCmd)
{
pCmd = pCmdHead = &(pInfo -> pEmbperlCmds[nNdx]) ;
- //??if (pCmd -> nNodeType != pNode -> nType)
- // pCmd = NULL ;
+ /* ??if (pCmd -> nNodeType != pNode -> nType) */
+ /* pCmd = NULL ; */
}
else
pCmd = pCmdHead = NULL ;
@@ -1241,18 +1241,18 @@
if (pCmd == NULL || (pCmd -> bRemoveNode & 1) == 0)
pDomTree -> xLastNode = xNode ;
- // if (*bCheckpointPending && (pNode -> nType == ntypText || pNode -> nType
== ntypCDATA) && pNode -> bFlags && (pNode -> bFlags & nflgIgnore) == 0)
-// if (*bCheckpointPending && pNode -> bFlags && (pNode -> bFlags &
nflgIgnore) == 0)
+ /* if (*bCheckpointPending && (pNode -> nType == ntypText || pNode -> nType
== ntypCDATA) && pNode -> bFlags && (pNode -> bFlags & nflgIgnore) == 0) */
+ /* if (*bCheckpointPending && pNode -> bFlags && (pNode -> bFlags &
nflgIgnore) == 0) */
if (*bCheckpointPending && !(pCmd && pCmd -> nSwitchCodeType == 2) &&
pNode -> bFlags && (pNode -> bFlags & nflgIgnore) == 0)
{
int l ;
char buf [80] ;
pNode -> bFlags |= nflgCheckpoint ;
- //l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n",
*bCheckpointPending<0?pNode -> xNdx:*bCheckpointPending) ;
- //l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n", pNode -> xNdx) ;
+ /* l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n",
*bCheckpointPending<0?pNode -> xNdx:*bCheckpointPending) ; */
+ /* l = sprintf (buf, " _ep_cp($_ep_DomTree,%d) ;\n", pNode -> xNdx) ; */
l = sprintf (buf, " _ep_cp(%d) ;\n", xNode) ;
- //l = sprintf (buf, " $_ep_cp=%d;\n", pNode -> xNdx) ;
+ /* l = sprintf (buf, " $_ep_cp=%d;\n", pNode -> xNdx) ; */
nCheckpointCodeOffset = StringAdd (r -> pProg, buf, l) ;
*bCheckpointPending = 0 ;
@@ -1367,7 +1367,7 @@
int l ;
char buf [80] ;
- l = sprintf (buf, " _ep_cp(%d) ;\n", -1) ; // xNode) ;
+ l = sprintf (buf, " _ep_cp(%d) ;\n", -1) ; /* xNode) ; */
StringAdd (r -> pProg, buf, l) ;
if (pCurrReq -> bDebug & dbgParse)
@@ -1483,9 +1483,13 @@
r -> nPhase = phCompile ;
if (ppLastResult && *ppLastResult && SvTYPE (*ppLastResult) == SVt_PVCV)
- { /* Get already parsed Dom Tree */
+ { /* Get already parsed Dom Tree */
if (ppCompResult != ppLastResult)
- AssignSVPtr (ppCompResult,*ppLastResult) ;
+ {
+ AssignSVPtr (ppCompResult,*ppLastResult) ;
+ SvREFCNT_inc (*ppCompResult) ;
+ }
+
return ok ;
}
@@ -1530,7 +1534,7 @@
if (l && pCurrReq -> bDebug & dbgParse)
lprintf (r, "[%d]EPCOMP: AfterCompileTimeCode: %*.*s\n", r -> nPid, l, l, r
-> pProgDef) ;
- //pSV = newSVpvf("package %s ; \nmy ($_ep_req, $_ep_DomTree) = @_;\n%*.*s", r
-> Buf.sEvalPackage, l,l, r -> pProgDef) ;
+ /* pSV = newSVpvf("package %s ; \nmy ($_ep_req, $_ep_DomTree) = @_;\n%*.*s", r
-> Buf.sEvalPackage, l,l, r -> pProgDef) ; */
pSV = newSVpvf("package %s ; \n%*.*s", r -> Buf.sEvalPackage, l,l, r ->
pProgDef) ;
args[0] = r -> pReqSV ;
args[1] = pDomTree -> pDomTreeSV ;
@@ -1576,95 +1580,8 @@
lprintf (r, "Setup source code for interactive debugger\n") ;
}
- if ((rc = EvalOnly (r, r -> pProgRun, ppCompResult, G_SCALAR, EPMAINSUB)) != ok)
- return rc ;
-
-#if 0
- /*xxx*/lprintf (r, "evalno = %d\n" , PL_evalseq - 1) ;
- //if (*ppSV && SvROK (*ppSV))
- //if (0)
- { /* copy debugging infos from eval gv to file gv (@/%_<filename) */
- AV * pAV ;
- HV * pHV ;
- char tmp [64] ;
- GV * pGVFile = gv_fetchfile (r -> Buf.pFile -> sSourcefile) ;
- GV * pGVEval ;
-
- sprintf (tmp, "(eval %lu)", PL_evalseq) ;
- pGVEval = gv_fetchfile (tmp) ;
-
- /*xxx*/lprintf (r, "file = %s %x eval = %s %x\n" , GvNAME(pGVFile), pGVFile,
GvNAME(pGVEval), pGVEval) ;
- if (pGVFile != pGVEval)
- {
- AV * pDebugArray = GvAV (pGVFile) ;
- AV * pEvalArray = GvAV (pGVEval) ;
- char * p ;
- char * end ;
- I32 i ;
-
- for (i = 0; i < AvFILL(pEvalArray); i++)
- {
- SV * pLine ;
- SV * * ppLine ;
- if ((ppLine = av_fetch (pEvalArray, i, 0)) && (pLine = *ppLine))
- {
- /* xxx */ lprintf (r, "Eval pLine %d type = %x, ", i,
SvTYPE(pLine)) ;
- /* xxx */ lprintf (r, "int = %d", SvIVX(pLine)) ;
- /* xxx */ lprintf (r, "str = %s\n", SvPVX(pLine)) ;
- }
- }
+ rc = EvalOnly (r, r -> pProgRun, ppCompResult, G_SCALAR, EPMAINSUB) ;
- for (i = 0; i < AvFILL(pDebugArray); i++)
- {
- SV * pLine ;
- SV * * ppLine ;
- if ((ppLine = av_fetch (pDebugArray, i, 0)) && (pLine = *ppLine))
- {
- /* xxx */ lprintf (r, "Debug pLine %d type = %x, ", i,
SvTYPE(pLine)) ;
- /* xxx */ lprintf (r, "int = %d", SvIVX(pLine)) ;
- /* xxx */ lprintf (r, "str = %s\n", SvPVX(pLine)) ;
- }
- }
-
-
- p = r -> Buf.pBuf ;
- i = 1 ;
- while (*p)
- {
- end = strchr (p, '\n') ;
- if (end)
- {
- SV * pLine ;
- SV * * ppLine ;
- /* lprintf (r, "i = %d len = %d, str = %s", i, end - p + 1, SvPV
(pLine, n)) ; */
- if ((ppLine = av_fetch (pEvalArray, i, 0)) && (pLine = *ppLine))
- {
- STRLEN len = end - p + 1 ;
- /* xxx */ lprintf (r, "pLine type = %x, ", SvTYPE(pLine)) ;
- /* xxx */ lprintf (r, "int = %d", SvIVX(pLine)) ;
- /* xxx */ lprintf (r, "str = %s\n", SvPVX(pLine)) ;
- SvREFCNT_inc (pLine) ;
- SvUPGRADE (pLine, SVt_PVMG) ;
- SvGROW (pLine, len + 1) ;
- Move (p, SvPVX(pLine), len+1, char) ;
- *(SvPVX(pLine) + len) = '\0' ;
- SvCUR_set (pLine, len) ;
- SvPOK_on (pLine) ;
- }
- else
- pLine = newSVpv (p, end - p + 1) ;
-
- av_store (pDebugArray, i++, pLine) ;
- p = end + 1 ;
- }
- else if (p < r -> Buf.pEndPos)
- {
- av_store (pDebugArray, i++, newSVpv (p, r -> Buf.pEndPos - p + 1))
;
- break ;
- }
- }
-#endif
-
StringFree (&r -> pProgRun) ;
StringFree (&r -> pProgDef) ;
@@ -1682,7 +1599,7 @@
}
#endif
- return ok ;
+ return rc ;
}
/* ------------------------------------------------------------------------ */
@@ -1715,12 +1632,15 @@
{ /* Get already parsed Dom Tree */
pDomTree = DomTree_selfSV(*ppLastResult) ;
if (ppCompResult != ppLastResult)
- AssignSVPtr (ppCompResult,*ppLastResult) ;
+ {
+ AssignSVPtr (ppCompResult,*ppLastResult) ;
+ SvREFCNT_inc (*ppCompResult) ;
+ }
}
else
{
- //if ((rc = ReadInputFile (r)) != ok)
- // return rc ;
+ /* if ((rc = ReadInputFile (r)) != ok) */
+ /* return rc ; */
if ((rc = ParseFile (r)) != ok)
{
return rc ;
@@ -1728,7 +1648,7 @@
pDomTree = DomTree_self (r -> xCurrDomTree) ;
AssignSVPtr (ppCompResult,SV_DomTree_self (pDomTree)) ;
- SvREFCNT_inc (*ppCompResult) ;
+ /* SvREFCNT_inc (*ppCompResult) ; */
/* add timestamp */
SvUPGRADE (*ppCompResult, SVt_PVNV) ;
SvNVX (*ppCompResult) = time (NULL) ;
@@ -1848,7 +1768,7 @@
nOrderNdx = SvIV (* av_fetch (pSaveAV, 2, 0)) ;
pCallerDomTree = DomTree_self (r -> xCurrDomTree) ;
- //xDocFraq = Node_replaceChildWithNode (pSubDomTree, pSubDomTree -> xDocument,
pCallerDomTree, r -> xCurrNode) ;
+ /* xDocFraq = Node_replaceChildWithNode (pSubDomTree, pSubDomTree -> xDocument,
pCallerDomTree, r -> xCurrNode) ; */
r -> xCurrNode = xDocFraq = Node_insertAfter (pSubDomTree, pSubDomTree ->
xDocument, pCallerDomTree, r -> xCurrNode) ;
/* Element_selfSetAttribut (pCallerDomTree, Node_self (pCallerDomTree,
xDocFraq), NULL, xOrderIndexAttr, NULL, nOrderNdx, 0) ; */
@@ -1939,6 +1859,10 @@
{
SV * pSVName = newSVpvf ("%s::_ep_sub_%s", r -> Buf.sEvalPackage,
sSubName) ;
rc = CallStoredCV (r, r -> pProgRun, (CV *)pSVName, 1, args, 0, &pSV) ;
+ if (pSVName)
+ SvREFCNT_dec (pSVName) ;
+ if (pSV)
+ SvREFCNT_dec (pSV) ;
}
else
{
@@ -2023,7 +1947,7 @@
if (nExpiresIn == 0 && !pExpiresCV)
{
- //*pppSV = (SV**)_malloc (r, sizeof (SV *)) ;
+ /* *pppSV = (SV**)_malloc (r, sizeof (SV *)) ; */
**pppSV = NULL ;
if (r -> bDebug & dbgCache)
lprintf (r, "[%d]CACHE: File: '%s' Processor: '%s' Step: '%s' Type:
'%c' not cached\n", r -> nPid, r -> Buf.pFile -> sSourcefile, pProcessor -> sName,
sStepName, cType) ;
@@ -2069,7 +1993,7 @@
return rcHashError ;
if (*bForceExpire)
- { // Expire the entry
+ { /* Expire the entry */
sv_setsv (*ppSV, &sv_undef) ;
if (r -> bDebug & dbgCache)
lprintf (r, "[%d]CACHE: Expired because entry depends other expired
entry\n", r -> nPid) ;
@@ -2079,7 +2003,7 @@
double nTimestamp = SvNOKp(*ppSV)?SvNVX(*ppSV):0 ;
if (nTimestamp + nExpiresIn <= time (NULL))
- { // Expire the entry
+ { /* Expire the entry */
sv_setsv (*ppSV, &sv_undef) ;
*bForceExpire = 1 ;
if (r -> bDebug & dbgCache)
@@ -2088,6 +2012,8 @@
}
+ if (*ppSV != NULL)
+/* ### */ lprintf (r, "[%d]CACHE: SvTYPE (*ppSV) = %d\n", r -> nPid, SvTYPE
(*ppSV)) ;
if (*ppSV != NULL && SvTYPE (*ppSV) == SVt_PV)
{
strncpy (r -> errdat1, SvPV(*ppSV, l), sizeof (r -> errdat1) - 1) ;
@@ -2124,7 +2050,7 @@
return rc ;
if (pRet && SvTRUE(pRet))
- { // Expire the entry
+ { /* Expire the entry */
sv_setsv (*ppSV, &sv_undef) ;
*bForceExpire = 1 ;
if (r -> bDebug & dbgCache)
@@ -2190,14 +2116,21 @@
*ppSV = newSVpvf ("%s\t%s", r -> errdat1, r -> errdat2) ;
SvUPGRADE (*ppSV, SVt_PVIV) ;
SvIVX (*ppSV) = rc ;
+/* ### */ lprintf (r, "[%d]temp: SvTYPE (*ppSV) = %d\n", r -> nPid, SvTYPE
(*ppSV)) ;
}
- if (r -> xCurrDomTree)
+ /*
+ if (r -> xCurrDomTree)
{
DomTree_delete(DomTree_self(r -> xCurrDomTree)) ;
r -> xCurrDomTree = 0 ;
}
+ */
if (pTempSV)
+ {
+/* ### */ lprintf (r, "[%d]temp: SvTYPE (*ppSV) = %d\n", r -> nPid, SvTYPE
(pTempSV)) ;
+
SvREFCNT_dec (pTempSV) ;
+ }
return rc ;
}
if (pTempSV)
@@ -2232,8 +2165,10 @@
if ((rc = embperl_GetFromCache (r, pProcessor, 'C', "Compiler", -1,
NULL, &bForceExpire, &pCVKey, &ppCompResult)) != ok)
return rc ;
+/* ### */ lprintf (r, "[%d]comp1: SvTYPE (*ppSV) = %d\n", r -> nPid, SvTYPE
(*ppCompResult)) ;
if ((rc = (*pProcessor -> pCompiler)(r, pProcessor, &pDomTree,
ppPreCompResult, ppCompResult)) != ok)
return rc ;
+/* ### */ lprintf (r, "[%d]comp2: SvTYPE (*ppSV) = %d\n", r -> nPid, SvTYPE
(*ppCompResult)) ;
}
if (!r -> bError && pProcessor -> pExecuter)
1.4.2.38 +63 -63 embperl/Attic/epdom.c
Index: epdom.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epdom.c,v
retrieving revision 1.4.2.37
retrieving revision 1.4.2.38
diff -u -r1.4.2.37 -r1.4.2.38
--- epdom.c 2001/05/11 07:13:48 1.4.2.37
+++ epdom.c 2001/05/15 14:19:47 1.4.2.38
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epdom.c,v 1.4.2.37 2001/05/11 07:13:48 richter Exp $
+# $Id: epdom.c,v 1.4.2.38 2001/05/15 14:19:47 richter Exp $
#
###################################################################################*/
@@ -19,21 +19,19 @@
HV * pStringTableHash ; /* Hash to translate strings to index number */
HE * * pStringTableArray ; /* Array with pointers to strings */
-tStringIndex * pFreeStringsNdx ; /* List of freed string indexes */
+static tStringIndex * pFreeStringsNdx ; /* List of freed string indexes */
tDomTree * pDomTrees ;
-tIndex * pFreeDomTrees ;
+static tIndex * pFreeDomTrees ;
-int nInitialNodePadSize = 196 ;
+static int nMemUsage = 0 ;
+static int numNodes = 0 ;
+static int numAttr = 0 ;
+static int numStr = 0 ;
+static int numPads = 0 ;
+static int numReplace = 0 ;
-int nMemUsage = 0 ;
-int numNodes = 0 ;
-int numAttr = 0 ;
-int numStr = 0 ;
-int numPads = 0 ;
-int numReplace = 0 ;
-
tIndex xNoName = 0 ;
tIndex xDomTreeAttr = 0 ;
tIndex xDocument ;
@@ -45,9 +43,9 @@
tIndex xCheckpointCache[512] ;
-tUInt8 * MemFree[256] ;
-tUInt8 * pMemLast = NULL ;
-tUInt8 * pMemEnd = NULL ;
+static tUInt8 * MemFree[256] ;
+static tUInt8 * pMemLast = NULL ;
+static tUInt8 * pMemEnd = NULL ;
struct tPad
{
@@ -186,7 +184,6 @@
return m ;
}
-//#define dom_free(s) (free(s))
void str_free (void * s)
{
@@ -581,27 +578,30 @@
{
HE * pHE = pStringTableArray[nNdx] ;
- SV * pSVNdx = HeVAL (pHE) ;
-
- SvREFCNT_dec (pSVNdx) ;
-
- /*
- if (nNdx < 6 || nNdx == 92)
- lprintf (pCurrReq, "free string %s (#%d) refcnt=%d\n", Ndx2String (nNdx),
nNdx, SvREFCNT(pSVNdx)) ;
- */
-
- if (SvREFCNT(pSVNdx) == 1)
- {
- int n ;
+ if (pHE)
+ {
+ SV * pSVNdx = HeVAL (pHE) ;
+
+ SvREFCNT_dec (pSVNdx) ;
+
+ /*
+ if (nNdx < 6 || nNdx == 92)
+ lprintf (pCurrReq, "free string %s (#%d) refcnt=%d\n", Ndx2String (nNdx),
nNdx, SvREFCNT(pSVNdx)) ;
+ */
+
+ if (SvREFCNT(pSVNdx) == 1)
+ {
+ int n ;
- /* lprintf (pCurrReq, "delete string %s (#%d)\n", Ndx2String (nNdx), nNdx) ; */
- hv_delete (pStringTableHash, HeKEY (pHE), HeKLEN(pHE), 0) ;
- pStringTableArray[nNdx] = NULL ;
- n = ArrayAdd (&pFreeStringsNdx, 1) ;
- pFreeStringsNdx[n] = nNdx ;
-
- numStr-- ;
- }
+ /* lprintf (pCurrReq, "delete string %s (#%d)\n", Ndx2String (nNdx), nNdx)
; */
+ hv_delete (pStringTableHash, HeKEY (pHE), HeKLEN(pHE), 0) ;
+ pStringTableArray[nNdx] = NULL ;
+ n = ArrayAdd (&pFreeStringsNdx, 1) ;
+ pFreeStringsNdx[n] = nNdx ;
+
+ numStr-- ;
+ }
+ }
}
@@ -787,7 +787,7 @@
while (n--)
{
- //pDomTree -> pLookup[pAttr -> xNdx] = NULL ;
+ /* pDomTree -> pLookup[pAttr -> xNdx] = NULL ; */
if (pAttr -> bFlags)
{
if (pAttr -> xName)
@@ -798,7 +798,7 @@
pAttr++ ;
}
/* lprintf (pCurrReq, "delete typ=%d Node xNdx=%d\n", pNode -> nType,
pNode -> xNdx) ; */
- //pDomTree -> pLookup[pNode -> xNdx] = NULL ;
+ /* pDomTree -> pLookup[pNode -> xNdx] = NULL ; */
if (pNode -> nText)
NdxStringFree (pNode -> nText) ;
@@ -1034,7 +1034,7 @@
/* ------------------------------------------------------------------------
interface Node {
- // NodeType
+ # NodeType
const unsigned short ELEMENT_NODE = 1;
const unsigned short ATTRIBUTE_NODE = 2;
const unsigned short TEXT_NODE = 3;
@@ -1050,8 +1050,8 @@
readonly attribute DOMString nodeName;
attribute DOMString nodeValue;
- // raises(DOMException) on setting
- // raises(DOMException) on retrieval
+ # raises(DOMException) on setting
+ # raises(DOMException) on retrieval
readonly attribute unsigned short nodeType;
readonly attribute Node parentNode;
@@ -1061,7 +1061,7 @@
readonly attribute Node previousSibling;
readonly attribute Node nextSibling;
readonly attribute NamedNodeMap attributes;
- // Modified in DOM Level 2:
+ # Modified in DOM Level 2:
readonly attribute Document ownerDocument;
Node insertBefore(in Node newChild,
in Node refChild)
@@ -1075,18 +1075,18 @@
raises(DOMException);
boolean hasChildNodes();
Node cloneNode(in boolean deep);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
void normalize();
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
boolean supports(in DOMString feature,
in DOMString version);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
readonly attribute DOMString namespaceURI;
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
attribute DOMString prefix;
- // raises(DOMException) on setting
+ # raises(DOMException) on setting
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
readonly attribute DOMString localName;
};
@@ -1821,8 +1821,8 @@
tNodeData * pNew = Node_newAndAppend (pRefNodeDomTree, pRefNode -> xParent,
NULL, pRefNode -> nLinenumber, sizeof (tNodeData)) ;
pNew -> xChilds = 0 ;
- pNew -> bFlags = 0 ; //nflgModified | nflgReturn ;
-
+ pNew -> bFlags = 0 ;
+
if (nEscMode != -1)
{
pNew -> nType = (nEscMode & 3)?ntypText:ntypCDATA ;
@@ -1841,7 +1841,7 @@
else
pNxtNode = Node_self (pRefNodeDomTree, pRefNode -> xNext) ; /* first one */
- //if ((pNxtNode -> bFlags & nflgModified) == 0)
+ /* if ((pNxtNode -> bFlags & nflgModified) == 0) */
{
pNxtNode -> xPrev = pNew -> xNdx ;
pRefNode -> xNext = pNew -> xNdx ;
@@ -1849,7 +1849,7 @@
pNew -> xNext = pNxtNode -> xNdx ;
}
- //DomTree_selfCheckpoint (pRefNodeDomTree, xRefNode, pNew -> xNdx) ;
+ /* DomTree_selfCheckpoint (pRefNodeDomTree, xRefNode, pNew -> xNdx) ; */
return pNew -> xNdx ;
}
@@ -2265,7 +2265,7 @@
if (pCurrReq -> bDebug & dbgParse)
{
lprintf (r, "[%d]toString: Failed to Replace Node=%d DomTree=%d
(initial OrderIndex %d, max = %d)\n", r -> nPid, pNode -> xNdx, pDomTree -> xNdx,
nOrderNdx, n-1) ;
- //for (i = nOrderNdx; i < n; i++)
+ /* for (i = nOrderNdx; i < n; i++) */
for (i = 0; i < 5; i++)
lprintf (r, "[%d]toString: %d = %d -> %d\n", r -> nPid, i,
pOrder[i].xFromNode, pOrder[i].xToNode) ;
}
@@ -2284,7 +2284,7 @@
else if (pNode -> nType == ntypDocumentFraq)
{
Node_toString (pDomTree, r, pNode -> xNdx) ;
- //oputs (r, "\r\n") ;
+ /* oputs (r, "\r\n") ;*/
}
else if (pNode -> nType == ntypTag || pNode -> nType == ntypStartTag)
{
@@ -2539,30 +2539,30 @@
Attr removeAttributeNode(in Attr oldAttr)
raises(DOMException);
NodeList getElementsByTagName(in DOMString name);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
DOMString getAttributeNS(in DOMString namespaceURI,
in DOMString localName);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
void setAttributeNS(in DOMString namespaceURI,
in DOMString qualifiedName,
in DOMString value)
raises(DOMException);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
void removeAttributeNS(in DOMString namespaceURI,
in DOMString localName)
raises(DOMException);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
Attr getAttributeNodeNS(in DOMString namespaceURI,
in DOMString localName);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
Attr setAttributeNodeNS(in Attr newAttr)
raises(DOMException);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
NodeList getElementsByTagNameNS(in DOMString namespaceURI,
in DOMString localName);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
boolean hasAttribute(in DOMString name);
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
boolean hasAttributeNS(in DOMString namespaceURI,
in DOMString localName);
};
@@ -2784,9 +2784,9 @@
readonly attribute DOMString name;
readonly attribute boolean specified;
attribute DOMString value;
- // raises(DOMException) on setting
+ # raises(DOMException) on setting
- // Introduced in DOM Level 2:
+ # Introduced in DOM Level 2:
readonly attribute Element ownerElement;
};
1.4.2.18 +2 -2 embperl/Attic/epdom.h
Index: epdom.h
===================================================================
RCS file: /home/cvs/embperl/Attic/epdom.h,v
retrieving revision 1.4.2.17
retrieving revision 1.4.2.18
diff -u -r1.4.2.17 -r1.4.2.18
--- epdom.h 2001/05/04 14:04:22 1.4.2.17
+++ epdom.h 2001/05/15 14:19:51 1.4.2.18
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epdom.h,v 1.4.2.17 2001/05/04 14:04:22 richter Exp $
+# $Id: epdom.h,v 1.4.2.18 2001/05/15 14:19:51 richter Exp $
#
###################################################################################*/
@@ -88,7 +88,7 @@
/* ------------------------------------------------------------------------
interface Node {
- // NodeType
+ # NodeType
const unsigned short ELEMENT_NODE = 1;
const unsigned short ATTRIBUTE_NODE = 2;
const unsigned short TEXT_NODE = 3;
1.23.4.9 +2 -1 embperl/epeval.c
Index: epeval.c
===================================================================
RCS file: /home/cvs/embperl/epeval.c,v
retrieving revision 1.23.4.8
retrieving revision 1.23.4.9
diff -u -r1.23.4.8 -r1.23.4.9
--- epeval.c 2001/03/27 11:52:07 1.23.4.8
+++ epeval.c 2001/05/15 14:19:56 1.23.4.9
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epeval.c,v 1.23.4.8 2001/03/27 11:52:07 richter Exp $
+# $Id: epeval.c,v 1.23.4.9 2001/05/15 14:19:56 richter Exp $
#
###################################################################################*/
@@ -696,6 +696,7 @@
/*in*/ int flags,
/*out*/ SV ** pRet)
{
+ dTHXsem
int num ;
SV * pSVErr ;
1.75.4.35 +6 -1 embperl/epmain.c
Index: epmain.c
===================================================================
RCS file: /home/cvs/embperl/epmain.c,v
retrieving revision 1.75.4.34
retrieving revision 1.75.4.35
diff -u -r1.75.4.34 -r1.75.4.35
--- epmain.c 2001/05/11 07:13:51 1.75.4.34
+++ epmain.c 2001/05/15 14:20:00 1.75.4.35
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epmain.c,v 1.75.4.34 2001/05/11 07:13:51 richter Exp $
+# $Id: epmain.c,v 1.75.4.35 2001/05/15 14:20:00 richter Exp $
#
###################################################################################*/
@@ -1891,6 +1891,11 @@
{
SvREFCNT_dec (f -> pExportHash) ;
f -> pExportHash = NULL ;
+ }
+ if (f -> pBufSV)
+ {
+ SvREFCNT_dec (f -> pBufSV) ;
+ f -> pBufSV = NULL ;
}
}
pNew = "Found" ;
1.19.4.8 +80 -1 embperl/epnames.h
Index: epnames.h
===================================================================
RCS file: /home/cvs/embperl/epnames.h,v
retrieving revision 1.19.4.7
retrieving revision 1.19.4.8
diff -u -r1.19.4.7 -r1.19.4.8
--- epnames.h 2001/05/11 07:13:52 1.19.4.7
+++ epnames.h 2001/05/15 14:20:04 1.19.4.8
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epnames.h,v 1.19.4.7 2001/05/11 07:13:52 richter Exp $
+# $Id: epnames.h,v 1.19.4.8 2001/05/15 14:20:04 richter Exp $
#
###################################################################################*/
@@ -117,6 +117,85 @@
#define InitialReq EMBPERL_InitialReq
#define pCurrReq EMBPERL_pCurrReq
+#define ArrayAdd EMBPERL_ArrayAdd
+#define ArrayClone EMBPERL_ArrayClone
+#define ArrayFree EMBPERL_ArrayFree
+#define ArrayGetSize EMBPERL_ArrayGetSize
+#define ArrayNew EMBPERL_ArrayNew
+#define ArraySet EMBPERL_ArraySet
+#define ArraySetSize EMBPERL_ArraySetSize
+#define ArraySub EMBPERL_ArraySub
+#define Attr_selfValue EMBPERL_Attr_selfValue
+#define BuildTokenTable EMBPERL_BuildTokenTable
+#define CallStoredCV EMBPERL_CallStoredCV
+#define DefaultTokenTable EMBPERL_DefaultTokenTable
+#define DomInit EMBPERL_DomInit
+#define DomStats EMBPERL_DomStats
+#define DomTree_alloc EMBPERL_DomTree_alloc
+#define DomTree_checkpoint EMBPERL_DomTree_checkpoint
+#define DomTree_clone EMBPERL_DomTree_clone
+#define DomTree_delete EMBPERL_DomTree_delete
+#define DomTree_discardAfterCheckpoint EMBPERL_DomTree_discardAfterCheckpoint
+#define DomTree_mvtTab EMBPERL_DomTree_mvtTab
+#define DomTree_new EMBPERL_DomTree_new
+#define DomTree_selfCheckpoint EMBPERL_DomTree_selfCheckpoint
+#define DomTree_selfDiscardAfterCheckpoint
EMBPERL_DomTree_selfDiscardAfterCheckpoint
+#define Element_selfGetAttribut EMBPERL_Element_selfGetAttribut
+#define Element_selfGetNthAttribut EMBPERL_Element_selfGetNthAttribut
+#define Element_selfRemoveAttribut EMBPERL_Element_selfRemoveAttribut
+#define Element_selfSetAttribut EMBPERL_Element_selfSetAttribut
+#define EvalStore EMBPERL_EvalStore
+#define NdxStringFree EMBPERL_NdxStringFree
+#define NodeList_toString EMBPERL_NodeList_toString
+#define Node_appendChild EMBPERL_Node_appendChild
+#define Node_childsText EMBPERL_Node_childsText
+#define Node_cloneNode EMBPERL_Node_cloneNode
+#define Node_insertAfter EMBPERL_Node_insertAfter
+#define Node_insertAfter_CDATA EMBPERL_Node_insertAfter_CDATA
+#define Node_newAndAppend EMBPERL_Node_newAndAppend
+#define Node_nextSibling EMBPERL_Node_nextSibling
+#define Node_previousSibling EMBPERL_Node_previousSibling
+#define Node_removeChild EMBPERL_Node_removeChild
+#define Node_replaceChildWithCDATA EMBPERL_Node_replaceChildWithCDATA
+#define Node_replaceChildWithNode EMBPERL_Node_replaceChildWithNode
+#define Node_replaceChildWithUrlDATA EMBPERL_Node_replaceChildWithUrlDATA
+#define Node_selfCloneNode EMBPERL_Node_selfCloneNode
+#define Node_selfCondCloneNode EMBPERL_Node_selfCondCloneNode
+#define Node_selfExpand EMBPERL_Node_selfExpand
+#define Node_selfLastChild EMBPERL_Node_selfLastChild
+#define Node_selfNextSibling EMBPERL_Node_selfNextSibling
+#define Node_selfNthChild EMBPERL_Node_selfNthChild
+#define Node_selfPreviousSibling EMBPERL_Node_selfPreviousSibling
+#define Node_selfRemoveChild EMBPERL_Node_selfRemoveChild
+#define Node_toString EMBPERL_Node_toString
+#define Node_toString2 EMBPERL_Node_toString2
+#define ParseFile EMBPERL_ParseFile
+#define String2NdxInc EMBPERL_String2NdxInc
+#define StringAdd EMBPERL_StringAdd
+#define StringFree EMBPERL_StringFree
+#define StringNew EMBPERL_StringNew
+#define dom_free EMBPERL_dom_free
+#define dom_malloc EMBPERL_dom_malloc
+#define dom_realloc EMBPERL_dom_realloc
+#define mydie EMBPERL_mydie
+#define nCheckpointCache EMBPERL_nCheckpointCache
+#define nCheckpointCacheMask EMBPERL_nCheckpointCacheMask
+#define nInitialNodePadSize EMBPERL_nInitialNodePadSize
+#define pDomTrees EMBPERL_pDomTrees
+#define pFreeDomTrees EMBPERL_pFreeDomTrees
+#define pStringTableArray EMBPERL_pStringTableArray
+#define pStringTableHash EMBPERL_pStringTableHash
+#define str_free EMBPERL_str_free
+#define str_malloc EMBPERL_str_malloc
+#define str_realloc EMBPERL_str_realloc
+#define xCheckpointCache EMBPERL_xCheckpointCache
+#define xDocument EMBPERL_xDocument
+#define xDocumentFraq EMBPERL_xDocumentFraq
+#define xDomTreeAttr EMBPERL_xDomTreeAttr
+#define xNoName EMBPERL_xNoName
+#define xOrderIndexAttr EMBPERL_xOrderIndexAttr
+
+
#ifndef PERL_VERSION
#include <patchlevel.h>
#define PERL_VERSION PATCHLEVEL
1.4.2.26 +15 -11 embperl/Attic/epparse.c
Index: epparse.c
===================================================================
RCS file: /home/cvs/embperl/Attic/epparse.c,v
retrieving revision 1.4.2.25
retrieving revision 1.4.2.26
diff -u -r1.4.2.25 -r1.4.2.26
--- epparse.c 2001/05/08 12:55:44 1.4.2.25
+++ epparse.c 2001/05/15 14:20:07 1.4.2.26
@@ -9,7 +9,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: epparse.c,v 1.4.2.25 2001/05/08 12:55:44 richter Exp $
+# $Id: epparse.c,v 1.4.2.26 2001/05/15 14:20:07 richter Exp $
#
###################################################################################*/
@@ -592,7 +592,7 @@
if (pToken -> nTextLen == 0)
continue ;
r = strnicmp (pCurr, pToken -> sText, pToken -> nTextLen) ;
- //if ((r == 0 && !(pAllChars [pCurr[pToken -> nTextLen] >> 3]
& (1 << (pCurr[pToken -> nTextLen] & 7)))) ||
+ /* if ((r == 0 && !(pAllChars [pCurr[pToken -> nTextLen] >> 3]
& (1 << (pCurr[pToken -> nTextLen] & 7)))) || */
if (r == 0 ||
*pCurr > *(pToken -> sText))
break ;
@@ -614,7 +614,7 @@
if (!pToken)
{
pCurr = c.pStart ;
- // bFollow = 0 ;
+ /* bFollow = 0 ; */
}
}
@@ -630,12 +630,14 @@
else
{
pToken = pNextTokenTab -> pContainsToken ;
- //if (pToken = pNextTokenTab -> pContainsToken)
- // {
- // unsigned char * pContains ;
- // if (!(pToken -> pInside) && (!(pContains = pToken ->
pContains) || !(pContains [*pCurr >> 3] & (1 << (*pCurr & 7)))))
- // pToken = NULL ;
- // }
+ /*
+ if (pToken = pNextTokenTab -> pContainsToken)
+ {
+ unsigned char * pContains ;
+ if (!(pToken -> pInside) && (!(pContains = pToken ->
pContains) || !(pContains [*pCurr >> 3] & (1 << (*pCurr & 7)))))
+ pToken = NULL ;
+ }
+ */
if (pToken && pToken -> sNodeName)
pNodeName = pToken -> sNodeName ;
@@ -760,11 +762,13 @@
while (pContains [*pEndCurr >> 3] & (1 << (*pEndCurr & 7)))
pEndCurr++ ;
nSkip = 0 ;
+ /*
if (pEndCurr == pCurr)
{
- //pEndCurr = NULL ;
- //pToken = NULL ;
+ pEndCurr = NULL ;
+ pToken = NULL ;
}
+ */
}
else
{
1.15.4.10 +3 -2 embperl/eputil.c
Index: eputil.c
===================================================================
RCS file: /home/cvs/embperl/eputil.c,v
retrieving revision 1.15.4.9
retrieving revision 1.15.4.10
diff -u -r1.15.4.9 -r1.15.4.10
--- eputil.c 2001/05/11 07:13:53 1.15.4.9
+++ eputil.c 2001/05/15 14:20:09 1.15.4.10
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: eputil.c,v 1.15.4.9 2001/05/11 07:13:53 richter Exp $
+# $Id: eputil.c,v 1.15.4.10 2001/05/15 14:20:09 richter Exp $
#
###################################################################################*/
@@ -883,10 +883,11 @@
/*in*/ const char * sPackage)
{
+ dTHXsem
SV * val;
char * key;
I32 klen;
- int bDebug = 1 ;
+ int bDebug = 0 ;
SV * sv;
HV * hv;
AV * av;
1.70.4.58 +5 -20 embperl/test.pl
Index: test.pl
===================================================================
RCS file: /home/cvs/embperl/test.pl,v
retrieving revision 1.70.4.57
retrieving revision 1.70.4.58
diff -u -r1.70.4.57 -r1.70.4.58
--- test.pl 2001/05/11 07:13:54 1.70.4.57
+++ test.pl 2001/05/15 14:20:12 1.70.4.58
@@ -11,7 +11,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: test.pl,v 1.70.4.57 2001/05/11 07:13:54 richter Exp $
+# $Id: test.pl,v 1.70.4.58 2001/05/15 14:20:12 richter Exp $
#
###################################################################################
@@ -104,6 +104,7 @@
'errors' => 6,
'version' => 2,
'cgi' => 0,
+ 'noloop' => 1,
},
'rawinput/rawinput.htm' => {
'option' => '16',
@@ -218,7 +219,7 @@
'upload.htm' => {
'query_info' => 'multval=A&multval=B&multval=C&single=S',
'offline' => 0,
-# 'noloop' => 1,
+ 'noloop' => 1,
'reqbody' => "Hi there!",
},
'reqrec.htm' => {
@@ -498,72 +499,56 @@
},
'EmbperlObject/epopage1.htm' => {
'offline' => 0,
- 'cgi' => 0,
'repeat' => 2,
},
'EmbperlObject/epoincdiv.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/epodiv.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/epopage2.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/epopage2.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/subsub/eposubsub.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/subsub/subsubsub/eposubsub.htm' => {
'offline' => 0,
- 'cgi' => 0,
'cmpext' => '3',
},
'EmbperlObject/sub/subsub/subsubsub/eposubsub2.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/eponotfound.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/sub/epobless.htm' => {
'offline' => 0,
- 'cgi' => 0,
'repeat' => 2,
},
'EmbperlObject/sub/epobless2.htm' => {
'offline' => 0,
- 'cgi' => 0,
'repeat' => 2,
},
'EmbperlObject/sub/epobless3.htm' => {
'offline' => 0,
- 'cgi' => 0,
'repeat' => 2,
},
'EmbperlObject/obj/epoobj1.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/obj/epoobj2.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/obj/epoobj3.htm' => {
'offline' => 0,
- 'cgi' => 0,
},
'EmbperlObject/obj/epoobj4.htm' => {
'offline' => 0,
- 'cgi' => 0,
'version' => 1,
},
'EmbperlObject/base2/epostopdir.htm' => {
@@ -639,7 +624,7 @@
use vars qw ($httpconfsrc $httpconf $EPPORT $EPPORT2 *SAVEERR *ERR $EPHTTPDDLL
$EPSTARTUP $EPDEBUG
$testshare
- $EPSESSIONDS $EPSESSIONCLASS $EPSESSIONVERSION $EP1COMPAT
+ $EPSESSIONDS $EPSESSIONCLASS $EPSESSIONVERSION $EP1COMPAT
$EPAPACHEVERSION
$opt_offline $opt_ep1 $opt_cgi $opt_modperl $opt_execute $opt_nokill
$opt_loop
$opt_multchild $opt_memcheck $opt_exitonmem $opt_exitonsv $opt_config
$opt_nostart $opt_uniquefn
$opt_quite $opt_qq $opt_ignoreerror $opt_tests $opt_blib $opt_help
$opt_dbgbreak $opt_finderr
@@ -1203,7 +1188,7 @@
$max_sv = $num_sv ;
}
- die "\n\nMemory problem (SVs)" if ($opt_exitonsv && $loopcnt > 2 &&
+ die "\n\nMemory problem (SVs)" if ($opt_exitonsv && $loopcnt > 3 &&
$testnum == $startnumber &&
$last_sv[$n] < $num_sv &&
$last_sv[$n] != 0 &&
No revision
No revision
1.1.2.11 +4 -3 embperl/Embperl/Syntax/Attic/SSI.pm
Index: SSI.pm
===================================================================
RCS file: /home/cvs/embperl/Embperl/Syntax/Attic/SSI.pm,v
retrieving revision 1.1.2.10
retrieving revision 1.1.2.11
diff -u -r1.1.2.10 -r1.1.2.11
--- SSI.pm 2001/03/28 19:15:33 1.1.2.10
+++ SSI.pm 2001/05/15 14:21:05 1.1.2.11
@@ -10,7 +10,7 @@
# IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
# WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
#
-# $Id: SSI.pm,v 1.1.2.10 2001/03/28 19:15:33 richter Exp $
+# $Id: SSI.pm,v 1.1.2.11 2001/05/15 14:21:05 richter Exp $
#
###################################################################################
@@ -18,12 +18,13 @@
use HTML::Embperl::Syntax qw{:types} ;
use HTML::Embperl::Syntax::HTML ;
-use Apache::Constants qw(:common OPT_INCNOEXEC);
use File::Basename;
BEGIN {
local $^W = 0 ;
require POSIX ;
+
+ eval "use Apache::Constants qw(:common OPT_INCNOEXEC);" ;
} ;
use strict ;
@@ -362,7 +363,7 @@
my $filename = $r->filename;
- die ("httpd: exec used but not allowed in $filename") if ($r->allow_options &
OPT_INCNOEXEC) ;
+ die ("httpd: exec used but not allowed in $filename") if ($r->allow_options &
&OPT_INCNOEXEC) ;
return scalar `$cmd` if ($cmd) ;
No revision
No revision
1.24.4.15 +9 -4 embperl/test/conf/httpd.conf.src
Index: httpd.conf.src
===================================================================
RCS file: /home/cvs/embperl/test/conf/httpd.conf.src,v
retrieving revision 1.24.4.14
retrieving revision 1.24.4.15
diff -u -r1.24.4.14 -r1.24.4.15
--- httpd.conf.src 2001/05/11 07:14:39 1.24.4.14
+++ httpd.conf.src 2001/05/15 14:21:13 1.24.4.15
@@ -294,6 +294,15 @@
Action text/html /cgi/embpcgi.test.pl
Options ExecCGI
</Location>
+
+SetEnv EMBPERL_OBJECT_BASE epobase.htm
+SetEnv EMBPERL_OBJECT_FALLBACK epofallback.htm
+
+<Location /cgi-bin/EmbperlObject>
+Action text/html /cgi/epocgi.test.pl
+Options ExecCGI
+</Location>
+
<Location /cgi-bin-32>
Action text/html /cgi/embpcgi.test.bat
@@ -367,10 +376,6 @@
PerlSetEnv EMBPERL_SYNTAX "Embperl SSI"
</Location>
-<Location /embperl/rtf/>
-PerlSetEnv EMBPERL_SYNTAX RTF
-</Location>
-
<Location /eg>
SetHandler perl-script
PerlHandler HTML::Embperl
No revision
No revision
1.1.4.7 +1 -1 embperl/test/html/rawinput/Attic/include.htm
Index: include.htm
===================================================================
RCS file: /home/cvs/embperl/test/html/rawinput/Attic/include.htm,v
retrieving revision 1.1.4.6
retrieving revision 1.1.4.7
diff -u -r1.1.4.6 -r1.1.4.7
--- include.htm 2001/05/02 11:54:57 1.1.4.6
+++ include.htm 2001/05/15 14:21:23 1.1.4.7
@@ -55,7 +55,6 @@
'package' => 'MyPackage::Interface',
req_rec => $req_rec}) ;
-]
-
<H1> 5.) Use \@param to pass parameters</H1>
@@ -65,6 +64,7 @@
param => [1, 2, 3, 4] }
) ;
-]
+
<H1> 6.) Use \@param to pass parameters and return it</H1>
No revision
No revision
1.2.6.2 +2 -1 embperl/test/html/registry/tied.htm
Index: tied.htm
===================================================================
RCS file: /home/cvs/embperl/test/html/registry/tied.htm,v
retrieving revision 1.2.6.1
retrieving revision 1.2.6.2
diff -u -r1.2.6.1 -r1.2.6.2
--- tied.htm 2000/12/04 13:38:19 1.2.6.1
+++ tied.htm 2001/05/15 14:21:34 1.2.6.2
@@ -73,7 +73,6 @@
mtime => 1}) ;
-
print "rc = $rc\n" ;
tie $tiedvar1, 'HTML::Embperl::Test::Tie', $tst1 ;
@@ -87,6 +86,8 @@
print "rc = $rc\n" ;
+
+
print "<HTML><TITLE>Test for HTML::Embperl::Execute</TITLE><BODY>\n" ;
print "<H1> 6.) Include from memory: tied string</H1>\n" ;
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]