[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: read -d'' -n1
From: |
Sharuzzaman Ahmat Raslan |
Subject: |
Re: read -d'' -n1 |
Date: |
Thu, 12 Aug 2010 13:50:34 +0800 |
Hi Jan,
Which part is the mistake, and what is the solution?
Thanks
On Thu, Aug 12, 2010 at 1:46 PM, Jan Schampera <jan.schampera@web.de> wrote:
> Jan Schampera wrote:
>
> 1) Why doesn't this print anything
>>
>> while read -d'' -n1 ch; do
>> echo "$ch"
>> done <<< $'hello\nworld'
>>
>>
>> 2) Why does this print something, but only up to the hyphen?
>>
>> while read -d'' -n1 ch; do
>> echo "$ch"
>> done <<< $'hello\nwor-ld'
>>
>
>
> Please ignore this question. 2 minutes after sending it, I saw my stupid
> mistake :(
>
> Sorry...
>
> J.
>
>
--
Sharuzzaman Ahmat Raslan