Kaydet (Commit) c4decc56 authored tarafından Caolán McNamara's avatar Caolán McNamara

coverity#1343620 Unchecked return value

Change-Id: I5ac69ef416a1317644b451442a51531806d9cf0d
üst 746da6b7
......@@ -233,9 +233,9 @@ PaperInfo PaperInfo::getSystemDefaultPaper()
char aBuffer[ 1024 ];
aBuffer[0] = 0;
char *pBuffer = fgets( aBuffer, sizeof(aBuffer), pPipe );
pclose( pPipe );
bool bOk = pclose(pPipe) == 0;
if (pBuffer && *pBuffer != 0)
if (bOk && pBuffer && *pBuffer != 0)
{
OString aPaper(pBuffer);
aPaper = aPaper.trim();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment