Print this page
3165 correct pointer to integer conversion in Privilege.xs

@@ -9,11 +9,11 @@
 /* Perl includes. */
 #include "EXTERN.h"
 #include "perl.h"
 #include "XSUB.h"
 
-#define IVCONST(s, c)   newCONSTSUB(s, #c, newSViv((int)c));
+#define IVCONST(s, c)   newCONSTSUB(s, #c, newSViv((int)(intptr_t)c));
 #define POFF            (sizeof ("PRIV_") - 1)
 
 #define RETPRIVSET(set)         \
         ST(0) = sv_newmortal();                                         \
         sv_setref_pv(ST(0), "Sun::Solaris::Privilege::PrivsetPtr",      \