perl-embperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Angus Lees <...@debian.org>
Subject bugfix and more warnings
Date Wed, 09 Apr 2003 13:29:52 GMT

the first hunk is a real bug. the fact that no-one noticed it implies
that this piece of code is never run..

the second hunk is a missing function declaration - needed for the new
iSetText function.

the third i think may have been a bug in my earlier patch. apparently
a tDomTree->xNdx is a tIndexShort, whereas a
{tAttrData,tNodeData}->xNdx is a tIndex.

the rest are some IV->I32 changes, which cause problems on 64bit-int
platforms (found from alpha compiler warnings).


i'm still trying to debug whats causing the spin on alpha and ia64. it
seems that if i run test 182 (SSI/ssibasic.htm) before running 189
(changeattr.htm), then 189 loops (works fine if i don't run 182).

the while loop in epdom.c:Attr_selfValue() seems to never drop out,
with the StringAdd() inside that loop appending either "b" or "" to
ppAttr each time around.

still gdbing..


diff -ru libembperl-perl-2.0b9dev6.before/DOM.xs libembperl-perl-2.0b9dev6/DOM.xs
--- libembperl-perl-2.0b9dev6.before/DOM.xs	2003-03-23 23:57:29.000000000 +0000
+++ libembperl-perl-2.0b9dev6/DOM.xs	2003-03-23 23:46:23.000000000 +0000
@@ -34,7 +34,7 @@
     SV *    pSV = SvRV(pRV) ;
     if ((mg = mg_find (pSV, '~')))
         {
-        pDomNode = (tDomNode *)(mg -> mg_len) ;
+        pDomNode = (tDomNode *)(mg -> mg_ptr) ;
         if (xDomTree)
             pDomNode -> xDomTree = xDomTree ;
         if (xNode)    
diff -u -r1.1.1.2 -r1.5
--- libembperl-perl-2.0b9dev6.before/epcomp.c	6 Apr 2003 12:47:34 -0000	1.1.1.2
+++ libembperl-perl-2.0b9dev6/epcomp.c	8 Apr 2003 13:26:34 -0000	1.5
@@ -827,7 +827,7 @@
 		    else if (*p == 'q')
 			{
 			char s [20] ;
-			int  l = sprintf (s, "%ld", pDomTree -> xNdx) ;
+			int  l = sprintf (s, "%hd", pDomTree -> xNdx) ;
 			StringAdd (r -> pApp, ppCode, s, l) ; 
 			}
 		    else if (*p == 'p')
diff -u -r1.1.1.1 -r1.2
--- libembperl-perl-2.0b9dev6.before/ep2.h	8 Dec 2002 02:10:42 -0000	1.1.1.1
+++ libembperl-perl-2.0b9dev6/ep2.h	8 Apr 2003 13:25:09 -0000	1.2
@@ -15,6 +15,14 @@
 ###################################################################################*/
 
 
+/* ---- from epdom.c ----- */
+
+
+void NdxStringFree (/*in*/ tApp * a,
+                    /*in*/ tStringIndex             nNdx) ;
+
+
+
 /* ---- from epcmd2.c ----- */
 
 
diff -u -r1.1.1.2 -r1.5
--- libembperl-perl-2.0b9dev6.before/epdom.c	6 Apr 2003 12:47:34 -0000	1.1.1.2
+++ libembperl-perl-2.0b9dev6/epdom.c	8 Apr 2003 12:12:07 -0000	1.5
@@ -211,7 +211,7 @@
     else
         {
         char buf[256] ;
-        sprintf (buf, "%d bytes", n) ;
+        sprintf (buf, "%zu bytes", n) ;
         LogErrorParam (a, rcOutOfMemory, "str_malloc failed", buf) ;
         }
 
@@ -266,7 +266,7 @@
     else
         {
         char buf[256] ;
-        sprintf (buf, "%d bytes", n) ;
+        sprintf (buf, "%zu bytes", n) ;
         LogErrorParam (a, rcOutOfMemory, "str_realloc failed", buf) ;
         }
     
diff -ru libembperl-perl-2.0b9dev6.before/Embperl.xs libembperl-perl-2.0b9dev6/Embperl.xs
--- libembperl-perl-2.0b9dev6.before/Embperl.xs	2002-10-22 10:33:21.000000000 +0000
+++ libembperl-perl-2.0b9dev6/Embperl.xs	2003-03-23 23:37:41.000000000 +0000
@@ -18,7 +18,7 @@
 
 
 /* for embperl_exit */
-static IV errgv_empty_set(pTHX_ IV ix, SV * sv)
+static I32 errgv_empty_set(pTHX_ IV ix, SV * sv)
 { 
     sv_setsv(sv, &sv_undef);
     return TRUE;
diff -ru libembperl-perl-2.0b9dev6.before/driver/eplibxslt.c libembperl-perl-2.0b9dev6/driver/eplibxslt.c
--- libembperl-perl-2.0b9dev6.before/driver/eplibxslt.c	2002-10-22 05:45:12.000000000 +0000
+++ libembperl-perl-2.0b9dev6/driver/eplibxslt.c	2003-03-23 23:57:02.000000000 +0000
@@ -86,7 +86,7 @@
     char *	    pKey ;
     SV *            pValue ;
     STRLEN          len ;
-    IV              l ;
+    I32             l ;
     int		    n ;
     const char * *  pParamArray ;
     const char *    sStylesheet ;
@@ -968,7 +968,7 @@
     char *	    pKey ;
     SV *            pValue ;
     STRLEN          len ;
-    IV		    l ;
+    I32		    l ;
     int		    n ;
     const char * *  pParamArray ;
     
diff -ru libembperl-perl-2.0b9dev6.before/epdom.c libembperl-perl-2.0b9dev6/epdom.c
--- libembperl-perl-2.0b9dev6.before/epdom.c	2003-03-23 23:57:29.000000000 +0000
+++ libembperl-perl-2.0b9dev6/epdom.c	2003-04-06 12:45:16.000000000 +0000
@@ -211,7 +211,7 @@
     else
         {
         char buf[256] ;
-        sprintf (buf, "%d bytes", n) ;
+        sprintf (buf, "%zu bytes", n) ;
         LogErrorParam (a, rcOutOfMemory, "str_malloc failed", buf) ;
         }
 
@@ -266,7 +266,7 @@
     else
         {
         char buf[256] ;
-        sprintf (buf, "%d bytes", n) ;
+        sprintf (buf, "%zu bytes", n) ;
         LogErrorParam (a, rcOutOfMemory, "str_realloc failed", buf) ;
         }
     
diff -ru libembperl-perl-2.0b9dev6.before/epparse.c libembperl-perl-2.0b9dev6/epparse.c
--- libembperl-perl-2.0b9dev6.before/epparse.c	2003-03-23 23:57:29.000000000 +0000
+++ libembperl-perl-2.0b9dev6/epparse.c	2003-03-23 23:53:07.000000000 +0000
@@ -77,7 +77,7 @@
     char *	    pKey ;
     SV * *	    ppSV ;
     SV * 	    pSVValue ;
-    IV		    l	 ;
+    I32		    l	 ;
     HV *            pHVProcInfo ;
     int             n ;
     epTHX ;
@@ -223,7 +223,7 @@
     int		    numTokens ;
     struct tToken * pTable ;
     struct tToken * p ;
-    IV		    l	 ;
+    I32		    l	 ;
     STRLEN	    len	 ;
     int		    n ;
     int		    i ;

---------------------------------------------------------------------
To unsubscribe, e-mail: embperl-unsubscribe@perl.apache.org
For additional commands, e-mail: embperl-help@perl.apache.org


Mime
View raw message