Skip to content

Commit 64aa248

Browse files
author
Raoul Zwart
committed
Fix: accept _both_ numbers and strings as offset parameter in filter specification.
1 parent 8b52fd9 commit 64aa248

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

perl-Net-HandlerSocket/HandlerSocket.xs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ sv_get_string_ref(SV *sv)
146146
static IV
147147
sv_get_iv(SV *sv)
148148
{
149-
if (sv == 0 || !SvIOK(sv) || !SvPOK(sv)) {
149+
if (sv == 0 || ( !SvIOK(sv) && !SvPOK(sv) ) ) {
150150
return 0;
151151
}
152152
return SvIV(sv);

0 commit comments

Comments
 (0)