зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1584785 - Fix issues found via PVS-studio static analyzer
Differential Revision: https://phabricator.services.mozilla.com/D47559 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
1e13189ecb
Коммит
05e7a5dee3
|
@ -1698,7 +1698,7 @@ nsresult nsSocketTransport::InitiateSocket() {
|
|||
//
|
||||
else {
|
||||
if (gSocketTransportService->IsTelemetryEnabledAndNotSleepPhase() &&
|
||||
connectStarted && connectStarted) {
|
||||
connectStarted && connectCalled) {
|
||||
SendPRBlockingTelemetry(
|
||||
connectStarted, Telemetry::PRCONNECT_FAIL_BLOCKING_TIME_NORMAL,
|
||||
Telemetry::PRCONNECT_FAIL_BLOCKING_TIME_SHUTDOWN,
|
||||
|
|
|
@ -226,7 +226,7 @@ BufferedOutgoingMsg::BufferedOutgoingMsg(OutgoingMsg& msg) {
|
|||
|
||||
BufferedOutgoingMsg::~BufferedOutgoingMsg() {
|
||||
delete mInfo;
|
||||
delete mData;
|
||||
delete[] mData;
|
||||
}
|
||||
|
||||
static int receive_cb(struct socket* sock, union sctp_sockstore addr,
|
||||
|
|
|
@ -688,8 +688,9 @@ int ParseFTPList(const char* line, struct list_state* state,
|
|||
}
|
||||
result->fe_type = 'f';
|
||||
pos = toklen[2];
|
||||
while (pos > (sizeof(result->fe_size) - 1))
|
||||
if (pos > (sizeof(result->fe_size) - 1)) {
|
||||
pos = (sizeof(result->fe_size) - 1);
|
||||
}
|
||||
memcpy(result->fe_size, tokens[2], pos);
|
||||
result->fe_size[pos] = '\0';
|
||||
} else {
|
||||
|
|
Загрузка…
Ссылка в новой задаче