mirror of
https://github.com/etlegacy/Update-Installer.git
synced 2024-11-10 06:31:49 +00:00
Fix comparison between pos and std::string::npos
std::string::npos is defined as the unsigned type size_t but given a value of -1, resulting in a warning when trying to compare an unsigned int with a size_t. Fix this by declaring pos as a size_t.
This commit is contained in:
parent
d922fc3f7a
commit
1318576cea
1 changed files with 1 additions and 1 deletions
|
@ -43,7 +43,7 @@ UpdateInstaller::Mode stringToMode(const std::string& modeStr)
|
|||
|
||||
void UpdaterOptions::parseOldFormatArg(const std::string& arg, std::string* key, std::string* value)
|
||||
{
|
||||
unsigned int pos = arg.find('=');
|
||||
size_t pos = arg.find('=');
|
||||
if (pos != std::string::npos)
|
||||
{
|
||||
*key = arg.substr(0,pos);
|
||||
|
|
Loading…
Reference in a new issue