cpp: Fix comparisons of integer expressions of different signedness
* lang/cpp/src/gpgrevokekeyeditinteractor.cpp (GpgRevokeKeyEditInteractor::Private::nextState): Cast signed nextLine value to std::size_t. --
This commit is contained in:
parent
dc9cc9aa07
commit
2e9d72a0be
@ -138,7 +138,7 @@ unsigned int GpgRevokeKeyEditInteractor::Private::nextState(unsigned int status,
|
||||
if (status == GPGME_STATUS_GET_LINE &&
|
||||
strcmp(args, "ask_revocation_reason.text") == 0) {
|
||||
nextLine++;
|
||||
return nextLine < reasonLines.size() ? REASON_TEXT : REASON_TEXT_DONE;
|
||||
return static_cast<std::size_t>(nextLine) < reasonLines.size() ? REASON_TEXT : REASON_TEXT_DONE;
|
||||
}
|
||||
err = GENERAL_ERROR;
|
||||
return ERROR;
|
||||
@ -147,7 +147,7 @@ unsigned int GpgRevokeKeyEditInteractor::Private::nextState(unsigned int status,
|
||||
if (status == GPGME_STATUS_GET_LINE &&
|
||||
strcmp(args, "ask_revocation_reason.text") == 0) {
|
||||
nextLine++;
|
||||
return nextLine < reasonLines.size() ? state + 1 : REASON_TEXT_DONE;
|
||||
return static_cast<std::size_t>(nextLine) < reasonLines.size() ? state + 1 : REASON_TEXT_DONE;
|
||||
}
|
||||
}
|
||||
err = GENERAL_ERROR;
|
||||
|
Loading…
Reference in New Issue
Block a user