diff options
Diffstat (limited to 'dist/IO/IO.xs')
-rw-r--r-- | dist/IO/IO.xs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/dist/IO/IO.xs b/dist/IO/IO.xs index d3dff557a2..08fefb0b6b 100644 --- a/dist/IO/IO.xs +++ b/dist/IO/IO.xs @@ -158,7 +158,11 @@ fgetpos(handle) if (fgetpos(handle, &pos)) { ST(0) = &PL_sv_undef; } else { +# if PERL_VERSION >= 11 + ST(0) = newSVpvn_flags((char*)&pos, sizeof(Fpos_t), SVs_TEMP); +# else ST(0) = sv_2mortal(newSVpvn((char*)&pos, sizeof(Fpos_t))); +# endif } #endif } |