mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-07-28 18:31:40 +00:00
Add explicit comparisons where we were implicitly checking for non-zero
* This fixes some warnings from PVS Studio, though none of these checks were actually wrong it's better to be explicit.
This commit is contained in:
@@ -413,7 +413,7 @@ struct LogLine
|
||||
if(idx + 64 > line.length())
|
||||
return false;
|
||||
|
||||
if(strncmp(&line[idx], "RDOC ", 5))
|
||||
if(strncmp(&line[idx], "RDOC ", 5) != 0)
|
||||
return false;
|
||||
|
||||
idx += 5;
|
||||
|
||||
@@ -63,7 +63,7 @@ Connection::Connection(Network::Socket *sock)
|
||||
char response[15] = {};
|
||||
reader.Read(response, handshakeLength);
|
||||
|
||||
if(memcmp(handshake, response, 14))
|
||||
if(memcmp(handshake, response, 14) != 0)
|
||||
{
|
||||
RDCERR("handshake failed - received >%s< - expected >%s<", response, handshake);
|
||||
error = true;
|
||||
|
||||
Reference in New Issue
Block a user