From: iceman1001 Date: Tue, 19 Jan 2016 18:52:01 +0000 (+0100) Subject: FIX: Coverity Scan warnings on not using the fread return value. X-Git-Url: http://cvs.zerfleddert.de/cgi-bin/gitweb.cgi/proxmark3-svn/commitdiff_plain/841d7af0dcaa91b937cd17631ee460cb5301d6ef?ds=inline;hp=-c FIX: Coverity Scan warnings on not using the fread return value. --- 841d7af0dcaa91b937cd17631ee460cb5301d6ef diff --git a/client/cmdhficlass.c b/client/cmdhficlass.c index cf0128be..70c18aba 100644 --- a/client/cmdhficlass.c +++ b/client/cmdhficlass.c @@ -1044,7 +1044,8 @@ int CmdHFiClassCloneTag(const char *Cmd) { // else we have to create a share memory int i; fseek(f,startblock*8,SEEK_SET); - if ( fread(tag_data,sizeof(iclass_block_t),endblock - startblock + 1,f) == 0){ + size_t bytes_read = fread(tag_data,sizeof(iclass_block_t),endblock - startblock + 1,f); + if ( bytes_read == 0){ PrintAndLog("File reading error."); fclose(f); return 2; diff --git a/client/cmdhfmf.c b/client/cmdhfmf.c index cf0f5c13..b189e19b 100644 --- a/client/cmdhfmf.c +++ b/client/cmdhfmf.c @@ -312,8 +312,10 @@ int CmdHF14AMfDump(const char *Cmd) } // Read keys A from file + size_t bytes_read; for (sectorNo=0; sectorNo