on 64-bit builds. Analysis and original patch
by Török Edwin. Code audit found another place
with the same problem, also fixed here.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45746
91177308-0d34-0410-b5e6-
96231b3b80d8
const std::string &TT = M.getTargetTriple();
if (TT.length() > 7) {
// Determine which version of darwin this is.
- unsigned DarwinPos = TT.find("-darwin");
+ size_t DarwinPos = TT.find("-darwin");
if (DarwinPos != std::string::npos) {
if (isdigit(TT[DarwinPos+7]))
DarwinVers = atoi(&TT[DarwinPos+7]);
// if one cannot be determined, to true.
const std::string& TT = M.getTargetTriple();
if (TT.length() > 5) {
- unsigned Pos;
+ size_t Pos;
if ((Pos = TT.find("-darwin")) != std::string::npos) {
TargetType = isDarwin;