Remove local variable masking a global one
As found by LGTM.com. Change-Id: Ied926a9eace9044ec9abc859557cd28178e5defb Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This commit is contained in:
parent
efdfdfa0fc
commit
89e3a426a8
@ -1631,8 +1631,7 @@ std::optional<QStringConverter::Encoding> QStringConverter::encodingForData(cons
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (arraySize > 2) {
|
if (arraySize > 2) {
|
||||||
static const char utf8bom[] = "\xef\xbb\xbf";
|
if (memcmp(buf, utf8bom, sizeof(utf8bom)) == 0)
|
||||||
if (memcmp(buf, utf8bom, sizeof(utf8bom) - 1) == 0)
|
|
||||||
return QStringConverter::Utf8;
|
return QStringConverter::Utf8;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user