Ciaran Finnegan a écrit :
> 
> Hi all, first post, so please be nice.
> 
> I've got a simple sockets server running
> 
> $local = IO::Socket::INET->new(Proto=>"tcp", LocalPort=>"23", Listen=>"1")
> or die "Can't open Socket\n";
> 
> $remote = $local->accept;
> 
> $remote->autoflush(1);
> 
> I'm reading input like so...
> 
> while (<$remote>) {print;
>                         }
> close $local, $remote
> 
> A hardware device connects to the socket and sends characters (barcode
> scanner output, variable length, alphanumeric) followed by '/r'
> 
> My (very basic) understanding is that if it used '/r/n' my code would work.
> 
> I don't have much control over the hardware side of things.
> 
> And as you can probably see I'm not too clued up on the software side of
> things.
> 
> tia
> 
> /ciaran.
> 
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]

simply use s/\r/\r\n/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to