There is a single unit test, which calls the internal ProcessMessage function. This is problematic, because it makes future changes harder, since they will need to carry over this public internal interface each time.
Also, there is a mixed use of pointers and references in p2p code, where just based on context, a pointer may sometimes assumed to be null, or non-null. This is confusing when reading the code, or making or reading future changes.
Fix both issues in a series of commits, to:
- refactor the single unit test to call higher-level functions
- Make
ProcessMessageprivate again - Use references instead of implicit non-null pointers, mostly in a scripted-diff