Prevent crashes due to missing or corrupted database records #1381

pull jgarzik wants to merge 2 commits into bitcoin:master from jgarzik:check-deser changing 4 files +37 −8
  1. jgarzik commented at 6:24 PM on May 22, 2012: contributor

    Any problems seen during deserialization will throw an uncaught exception, crashing the entire bitcoin process. Properly return an error instead, so that we may at least log the error and gracefully shutdown other portions of the app.

  2. gavinandresen commented at 6:47 PM on May 22, 2012: contributor

    ACK, long overdue. Compiled and ran on my Mac.

  3. Prevent crashes due to missing or corrupted database records
    Any problems seen during deserialization will throw an uncaught
    exception, crashing the entire bitcoin process.  Properly return an
    error instead, so that we may at least log the error and gracefully
    shutdown other portions of the app.
    f94b64c2f3
  4. Prevent crashes due to missing or corrupted blk????.dat records
    In LoadExternalBlockFile(), errors are already caught... silently.
    Add a warning message, even though we do not abort the program due to
    load error.
    8fe791e4e2
  5. jgarzik commented at 7:25 PM on May 22, 2012: contributor

    Added new commit, catching deser exceptions for CAutoFile (blknnnn.dat) too.

  6. jgarzik referenced this in commit 5d0f7c4f47 on May 22, 2012
  7. jgarzik merged this on May 22, 2012
  8. jgarzik closed this on May 22, 2012

  9. coblee referenced this in commit f23e260f17 on Jul 17, 2012
  10. jgarzik deleted the branch on Aug 24, 2014
  11. lateminer referenced this in commit b672681748 on Jan 22, 2019
  12. lateminer referenced this in commit 88256004a3 on May 6, 2020
  13. DrahtBot locked this on Sep 8, 2021

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-20 00:16 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me