]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commit - gdb/ChangeLog
gdb: fix shellcheck warnings SC2166 (&& and !! instead of -a and -o) in gdbarch.sh
authorSimon Marchi <simon.marchi@efficios.com>
Thu, 30 Apr 2020 00:35:34 +0000 (20:35 -0400)
committerSimon Marchi <simon.marchi@efficios.com>
Thu, 30 Apr 2020 00:35:34 +0000 (20:35 -0400)
commit759cea5e3f7f141abfc2f31d5039cd7f109edf95
tree90dbb8dcc0a47fb278aa018316d585469ae16a5f
parentcb02ab2416c2d83ca053652a21788189f3f7779f
gdb: fix shellcheck warnings SC2166 (&& and !! instead of -a and -o) in gdbarch.sh

Fix all warnings of this type:

    In gdbarch.sh line 1238:
        if [ "x${invalid_p}" = "x0" -a -n "${postdefault}" ]
                                    ^-- SC2166: Prefer [ p ] && [ q ] as [ p -a q ] is not well defined.

See the rationale here [1].

[1] https://github.com/koalaman/shellcheck/wiki/SC2166

gdb/ChangeLog:

* gdbarch.sh: Use shell operators && and || instead of
-a and -o.
gdb/ChangeLog
gdb/gdbarch.sh