[gold] -thinlto-object-suffix-replace: don't append new suffix if path does not end with old suffix

Summary: This is to be consistent with lld behavior since rLLD340364.

Reviewers: tejohnson

Reviewed By: tejohnson

Subscribers: steven_wu, eraman, mehdi_amini, inglorion, dexonsmith, llvm-commits

Differential Revision: https://reviews.llvm.org/D51060

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@340380 91177308-0d34-0410-b5e6-96231b3b80d8
2 files changed