gdb/amd64: clean up unused variable
authorEnze Li <enze.li@hotmail.com>
Mon, 1 Aug 2022 22:11:50 +0000 (06:11 +0800)
committerEnze Li <enze.li@hotmail.com>
Wed, 3 Aug 2022 12:28:07 +0000 (20:28 +0800)
commit8b8da1a9f31941fa167c9f2bd2a80cdd1dccb452
tree40b6c6ee15dbada3858e4c0f4777d655d80e8a4d
parentf74a5e6f2ed5180ce28d6478a6d7a7a1982c5d43
gdb/amd64: clean up unused variable

When building with clang 15, I got this,

  CXX    amd64-tdep.o
amd64-tdep.c:1410:13: error: variable 'insn' set but not used[-Werror,-Wunused-but-set-variable]
    gdb_byte *insn = insn_details->raw_insn + modrm_offset;
                ^
1 error generated.

The function that uses this variable has been removed in this commit,

commit 870f88f7551b0f2d6aaaa36fb684b5ff8f468107
Date:   Mon Apr 18 13:16:27 2016 -0400

    remove trivialy unused variables

Fix this by removing unused variable.

Tested by rebuilding on x86_64-linux with clang 15 and gcc 12.
gdb/amd64-tdep.c