Skip to content

Conversation

@jonatack
Copy link
Member

Noticed while compiling master:

net.cpp: In member function ‘void CConnman::AcceptConnection(const CConnman::ListenSocket&)’:
net.cpp:1041:10: warning: variable ‘legacyWhitelisted’ set but not used [-Wunused-but-set-variable]
 1041 |     bool legacyWhitelisted = false;
      |          ^~~~~~~~~~~~~~~~~

@fanquake fanquake added the P2P label Dec 28, 2020
@jonatack
Copy link
Member Author

Curious that I didn't see this before. It's very late but will look at the context tomorrow how this became orphaned.

@jonatack jonatack changed the title p2p: remove unused legacyWhitelisted bool variable p2p: remove unused legacyWhitelisted in AcceptConnection() Dec 29, 2020
@glozow
Copy link
Member

glozow commented Dec 29, 2020

utACK 8f9ca31

I think this is leftover from #20755 (from this comment about it), looks like you saw it like 2 hours after merge hahaha

@jonatack
Copy link
Member Author

Ah, it's from b1a936d

@jonatack
Copy link
Member Author

Thanks @glozow! Looks like we arrived at the same source in different ways.

@mjdietzx
Copy link
Contributor

ack 8f9ca31

@maflcko
Copy link
Member

maflcko commented Dec 29, 2020

Looks like gcc is required to get this warning. Using clang version 11.0.0 doesn't say anything.

@maflcko
Copy link
Member

maflcko commented Dec 29, 2020

review ACK 8f9ca31

@maflcko maflcko merged commit 069f37c into bitcoin:master Dec 29, 2020
@jonatack jonatack deleted the rm-unused-legacyWhitelisted branch December 29, 2020 08:12
sidhujag pushed a commit to syscoin/syscoin that referenced this pull request Dec 29, 2020
…nnection()

8f9ca31 p2p: remove unused legacyWhitelisted variable (Jon Atack)

Pull request description:

  Noticed while compiling master:

  ```
  net.cpp: In member function ‘void CConnman::AcceptConnection(const CConnman::ListenSocket&)’:
  net.cpp:1041:10: warning: variable ‘legacyWhitelisted’ set but not used [-Wunused-but-set-variable]
   1041 |     bool legacyWhitelisted = false;
        |          ^~~~~~~~~~~~~~~~~
  ```

ACKs for top commit:
  glozow:
    utACK bitcoin@8f9ca31
  MarcoFalke:
    review ACK 8f9ca31

Tree-SHA512: e3fb94d3d34b364b063a115ef9ed06cfd58729a790ba6ed27c7c32430fabf3ca0aa61bc6d33a1236bff802302779c8db28af351208f06c09ad12ce4873c244a6
@practicalswift
Copy link
Contributor

Post merge ACK: thanks for cleaning up! :)

@bitcoin bitcoin locked as resolved and limited conversation to collaborators Feb 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants