setaccount should not create new accounts if provided with an invalid address #98

pull TheBlueMatt wants to merge 2 commits into bitcoin:master from TheBlueMatt:setaccountfix changing 1 files +6 −0
  1. TheBlueMatt commented at 2:37 PM on March 5, 2011: member

    Simple solution to just return an error if the address provided is invalid.

  2. setaccount should return if an invalid address is provided.
    This prevents setaccount from creating new accounts which do not have any addresses.
    279ab5e62f
  3. gavinandresen commented at 2:57 PM on March 5, 2011: contributor

    Good idea.

  4. tcatm commented at 3:00 PM on March 5, 2011: none

    Shouldn't it throw JSONRPCError(-5, "Invalid bitcoin address") like getreceivedbyaddress does?

  5. throw JSONRPCError(-5, "Invalid bitcoin address") instead. c1f74f152b
  6. glv2 referenced this in commit 5100d21c7b on Apr 15, 2014
  7. glv2 referenced this in commit 65e23cea45 on Aug 19, 2014
  8. rdponticelli referenced this in commit 7ff4770e15 on Nov 26, 2014
  9. zathras-crypto referenced this in commit 556fd42572 on Jun 26, 2015
  10. MarcoFalke referenced this in commit c1a337da86 on Mar 26, 2016
  11. ptschip referenced this in commit 1b4f7424e5 on Sep 24, 2016
  12. CryptAxe referenced this in commit 16ec16b1c8 on May 14, 2018
  13. lateminer referenced this in commit c67ca468be on Feb 23, 2019
  14. rajarshimaitra referenced this in commit 784490688b on Aug 5, 2021
  15. 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-13 21:16 UTC

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