The suggested patch for [perl #22201] "patch: perl 5.8.0
Jarkko Hietaniemi [Fri, 16 May 2003 18:21:27 +0000 (18:21 +0000)]
compile error on ia64/HP-UX (comparing incompatible pointers)"
plus a possible cure for the warning mentioned in the case.

p4raw-id: //depot/perl@19532

ext/Storable/Storable.xs

index 41dffca..a1208de 100644 (file)
@@ -470,7 +470,7 @@ static stcxt_t *Context_ptr = NULL;
        if (!mbase) {                                           \
                TRACEME(("** allocating mbase of %d bytes", MGROW)); \
                New(10003, mbase, MGROW, char); \
-               msiz = MGROW;                                   \
+               msiz = (STRLEN)MGROW;                                   \
        }                                                                       \
        mptr = mbase;                                           \
        if (x)                                                          \
@@ -1322,7 +1322,8 @@ static void init_retrieve_context(stcxt_t *cxt, int optype, int is_tainted)
         * new retrieve routines.
         */
 
-       cxt->hseen = ((cxt->retrieve_vtbl == sv_old_retrieve) ? newHV() : 0);
+       cxt->hseen = (((void*)cxt->retrieve_vtbl == (void*)sv_old_retrieve)
+                     ? newHV() : 0);
 
        cxt->aseen = newAV();                   /* Where retrieved objects are kept */
        cxt->aclass = newAV();                  /* Where seen classnames are kept */