Release cs_main before calling ProcessNewBlock, or processing headers (cmpctblock handling) #9252

pull sdaftuar wants to merge 2 commits into bitcoin:master from sdaftuar:cb-lock changing 1 files +22 −4
  1. sdaftuar commented at 6:57 pm on November 30, 2016: member
    If a compact block reconstructed successfully without any getblocktxn roundtrip, then we were calling ProcessNewBlock with cs_main held.
  2. TheBlueMatt commented at 7:17 pm on November 30, 2016: member
    Arg. utACK 19d7db214da39765c048d1350ef368aedf858ca8
  3. in src/main.cpp: in 19d7db214d outdated
    5885@@ -5880,6 +5886,10 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv,
    5886                 return ProcessMessage(pfrom, NetMsgType::HEADERS, vHeadersMsg, nTimeReceived, chainparams, connman);
    5887             }
    5888         }
    5889+        } // cs_main
    5890+
    5891+        if (fBlockReconstructed)
    5892+            return ProcessMessage(pfrom, NetMsgType::BLOCKTXN, blockTxnMsg, nTimeReceived, chainparams, connman);
    


    ryanofsky commented at 7:22 pm on November 30, 2016:
    Looks like cs_main is still held during the ProcessMessage call above on line 5886. Maybe deserves a comment if this is intentional.

    TheBlueMatt commented at 7:26 pm on November 30, 2016:
    Oh, actually this is not intentional, this is a separate bug.

    sdaftuar commented at 3:42 pm on December 1, 2016:
    Added a commit that addresses this one as well.
  4. fanquake added the label Refactoring on Dec 1, 2016
  5. jonasschnelli added the label Needs backport on Dec 1, 2016
  6. sdaftuar renamed this:
    Release cs_main before calling ProcessNewBlock (cmpctblock handling)
    Release cs_main before calling ProcessNewBlock, or processing headers (cmpctblock handling)
    on Dec 1, 2016
  7. morcos commented at 8:41 pm on December 1, 2016: member
    @fanquake when you get a chance, this no longer needs backporting (see above 9259 which was closed)
  8. TheBlueMatt commented at 10:08 pm on December 1, 2016: member
    re-utACK 8c2e1c072a8c87b6fc1832e62f55e275284e7a3a (without backport)
  9. sipa removed the label Needs backport on Dec 1, 2016
  10. MarcoFalke commented at 2:53 pm on December 2, 2016: member
    utACK, needs rebase.
  11. sdaftuar force-pushed on Dec 2, 2016
  12. morcos commented at 4:23 pm on December 2, 2016: member
    utACK 0f1190f
  13. gmaxwell commented at 9:29 am on December 10, 2016: contributor
    still needs rebase.
  14. sdaftuar force-pushed on Dec 11, 2016
  15. sdaftuar commented at 1:39 am on December 11, 2016: member
    Rebased.
  16. TheBlueMatt commented at 3:33 am on December 24, 2016: member
    Needs rebase again :/
  17. Release cs_main before calling ProcessNewBlock (cmpctblock handling) 680b0c0138
  18. Release cs_main before processing cmpctblock as header bd02bddb93
  19. sdaftuar force-pushed on Dec 26, 2016
  20. sdaftuar commented at 10:42 am on December 26, 2016: member
    Rebased.
  21. sipa commented at 6:25 pm on December 27, 2016: member
    utACK bd02bddb938fa7ddf4e5dc7c3ce2a787feba848a
  22. morcos commented at 8:27 pm on January 3, 2017: member
    lightly tested reACK bd02bdd
  23. sipa merged this on Jan 3, 2017
  24. sipa closed this on Jan 3, 2017

  25. sipa referenced this in commit ce5c1f4aca on Jan 3, 2017
  26. gladcow referenced this in commit f29497c95f on Mar 5, 2018
  27. gladcow referenced this in commit 8ca015d698 on Mar 8, 2018
  28. gladcow referenced this in commit 05a6ea9cdb on Mar 13, 2018
  29. gladcow referenced this in commit 182106b938 on Mar 14, 2018
  30. gladcow referenced this in commit 6283f86906 on Mar 15, 2018
  31. gladcow referenced this in commit b4f02d36f5 on Mar 15, 2018
  32. gladcow referenced this in commit 42b554dbb1 on Mar 15, 2018
  33. gladcow referenced this in commit 38c9610cd2 on Mar 15, 2018
  34. gladcow referenced this in commit f732196dfc on Mar 24, 2018
  35. gladcow referenced this in commit 085e9ce46b on Apr 4, 2018
  36. UdjinM6 referenced this in commit bc45a2f87a on Apr 11, 2018
  37. andvgal referenced this in commit fd5c50bc2b on Jan 6, 2019
  38. CryptoCentric referenced this in commit dd3fd51204 on Feb 28, 2019
  39. 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: 2024-11-17 15:12 UTC

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