… | |
… | |
755 | $_[0]{oobinline} = $_[1]; |
755 | $_[0]{oobinline} = $_[1]; |
756 | |
756 | |
757 | eval { |
757 | eval { |
758 | local $SIG{__DIE__}; |
758 | local $SIG{__DIE__}; |
759 | setsockopt $_[0]{fh}, Socket::SOL_SOCKET (), Socket::SO_OOBINLINE (), int $_[1] |
759 | setsockopt $_[0]{fh}, Socket::SOL_SOCKET (), Socket::SO_OOBINLINE (), int $_[1] |
760 | if $_[0]{fh}; |
|
|
761 | }; |
|
|
762 | } |
|
|
763 | |
|
|
764 | =item $handle->keepalive ($boolean) |
|
|
765 | |
|
|
766 | Enables or disables the C<keepalive> setting (see constructor argument of |
|
|
767 | the same name for details). |
|
|
768 | |
|
|
769 | =cut |
|
|
770 | |
|
|
771 | sub keepalive { |
|
|
772 | $_[0]{keepalive} = $_[1]; |
|
|
773 | |
|
|
774 | eval { |
|
|
775 | local $SIG{__DIE__}; |
|
|
776 | setsockopt $_[0]{fh}, Socket::SOL_SOCKET (), Socket::SO_KEEPALIVE (), int $_[1] |
|
|
777 | if $_[0]{fh}; |
760 | if $_[0]{fh}; |
778 | }; |
761 | }; |
779 | } |
762 | } |
780 | |
763 | |
781 | =item $handle->on_starttls ($cb) |
764 | =item $handle->on_starttls ($cb) |