use standard __func__ instead of __PRETTY_FUNCTION__

This commit is contained in:
Philip Kaufmann 2014-04-30 14:45:24 +02:00 committed by langerhans
parent 587c08f3d2
commit c8ccf30103
3 changed files with 7 additions and 7 deletions

View file

@ -1039,11 +1039,11 @@ bool GetTransaction(const uint256 &hash, CTransaction &txOut, uint256 &hashBlock
fseek(file, postx.nTxOffset, SEEK_CUR); fseek(file, postx.nTxOffset, SEEK_CUR);
file >> txOut; file >> txOut;
} catch (std::exception &e) { } catch (std::exception &e) {
return error("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); return error("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
hashBlock = header.GetHash(); hashBlock = header.GetHash();
if (txOut.GetHash() != hash) if (txOut.GetHash() != hash)
return error("%s : txid mismatch", __PRETTY_FUNCTION__); return error("%s : txid mismatch", __func__);
return true; return true;
} }
} }
@ -1127,7 +1127,7 @@ bool ReadBlockFromDisk(CBlock& block, const CDiskBlockPos& pos)
filein >> block; filein >> block;
} }
catch (std::exception &e) { catch (std::exception &e) {
return error("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); return error("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
// Check the header // Check the header
@ -3317,7 +3317,7 @@ bool LoadExternalBlockFile(FILE* fileIn, CDiskBlockPos *dbp)
break; break;
} }
} catch (std::exception &e) { } catch (std::exception &e) {
LogPrintf("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); LogPrintf("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
} }
fclose(fileIn); fclose(fileIn);

View file

@ -400,7 +400,7 @@ public:
filein >> hashChecksum; filein >> hashChecksum;
} }
catch (std::exception &e) { catch (std::exception &e) {
return error("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); return error("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
// Verify checksum // Verify checksum

View file

@ -148,7 +148,7 @@ bool CCoinsViewDB::GetStats(CCoinsStats &stats) {
} }
pcursor->Next(); pcursor->Next();
} catch (std::exception &e) { } catch (std::exception &e) {
return error("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); return error("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
} }
delete pcursor; delete pcursor;
@ -226,7 +226,7 @@ bool CBlockTreeDB::LoadBlockIndexGuts()
break; // if shutdown requested or finished loading block index break; // if shutdown requested or finished loading block index
} }
} catch (std::exception &e) { } catch (std::exception &e) {
return error("%s : Deserialize or I/O error - %s", __PRETTY_FUNCTION__, e.what()); return error("%s : Deserialize or I/O error - %s", __func__, e.what());
} }
} }
delete pcursor; delete pcursor;