Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #11279

BUG?: (or what's going on?) test for NL == NL fails (bash-4.3.39(3)-release)

From Linda Walsh <bash@tlinx.org>
Newsgroups gnu.bash.bug
Subject BUG?: (or what's going on?) test for NL == NL fails (bash-4.3.39(3)-release)
Date 2015-08-02 12:30 -0700
Message-ID <mailman.7763.1438543814.904.bug-bash@gnu.org> (permalink)

Show all headers | View raw


>  printf "\n" |hexdump -C        
00000000  0a
>  printf "%s" $'\n'|hexdump -C
00000000  0a
>  if [[ $(printf "\n") == $'\n' ]]; then echo T; else echo F; fi
F

----
just noticed the problem doesn't happen if I try to use '\t' (tab)

>  printf "\t" |hexdump -C        
00000000  09
>  printf "%s" $'\t'|hexdump -C
00000000  09
>  if [[ $(printf "\t") == $'\t' ]]; then echo T; else echo F; fi
T



Back to gnu.bash.bug | Previous | Next | Find similar


Thread

BUG?: (or what's going on?) test for NL == NL fails (bash-4.3.39(3)-release) Linda Walsh <bash@tlinx.org> - 2015-08-02 12:30 -0700

csiph-web