[Pkg-haskell-maintainers] Bug#753959: shellcheck: false negative with another bad use of ls

Paul Wise pabs at debian.org
Sun Jul 6 17:05:05 UTC 2014


Package: shellcheck
Version: 0.3.3-1
Severity: normal

shellcheck doesn't detect this bad use of ls (SC2045) from [1]:

# BAD! Don't do this!
arr=($(ls)) # Word-splitting and globbing here, same mistake as above
for f in "${arr[@]}"; do
    echo "$f"
done

     1. http://mywiki.wooledge.org/ParsingLs

-- System Information:
Debian Release: jessie/sid
  APT prefers testing
  APT policy: (900, 'testing'), (800, 'unstable'), (700, 'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 3.14-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_AU.UTF-8, LC_CTYPE=en_AU.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages shellcheck depends on:
ii  libc6     2.19-4
ii  libffi6   3.1-2
ii  libgmp10  2:6.0.0+dfsg-4

shellcheck recommends no packages.

shellcheck suggests no packages.

-- no debconf information

-- 
bye,
pabs

http://wiki.debian.org/PaulWise
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: This is a digitally signed message part
URL: <http://lists.alioth.debian.org/pipermail/pkg-haskell-maintainers/attachments/20140707/d900da6e/attachment.sig>


More information about the Pkg-haskell-maintainers mailing list