In my app, I receive strings, massage them, and use push_write() to enqueue
them.

Occasionally, my app receives a unicoded string...
so when the write happens, push_write() dies with the error:

   Wide character in subroutine entry at ...

because of the else clause in this snippet from push_write():

   if ($self->{tls}) {
      utf8::downgrade $self->{_tls_wbuf} .= $_[0];
      &_dotls ($self)    if $self->{fh};
   } else {
      utf8::downgrade $self->{wbuf}      .= $_[0];
      $self->_drain_wbuf if $self->{fh};
   }

I want/need? to be able to treat the AnyEvent handle/data-path as an octet
path
and not unicode (because any unicode-iness is between the originator
and the ultimate destination, and not my code, nor handle in between.)

What I haven't figured out yet is how to either:

a) coerce the character string into an octet string
   (for the rest of its life, ie. in subsequent modules)
   so the warning/dying goes away.
b) add something (???) so that it go through that code.

What is the correct process I should use?

TIA
Fulko
_______________________________________________
anyevent mailing list
[email protected]
http://lists.schmorp.de/mailman/listinfo/anyevent

Reply via email to