saltyrtc / saltyrtc-client-java

SaltyRTC Java implementation.
Apache License 2.0
3 stars 4 forks source link

Question about source code #119

Closed ovalseven8 closed 5 years ago

ovalseven8 commented 5 years ago

I skimmed a little through the code and wonder if CLOSING_NORMAL is missing here? However, I am not that familiar with the SaltyRTC protocol.

https://github.com/saltyrtc/saltyrtc-client-java/blob/f988042bc5fa2196014ba8a5d6d87104eab24554/src/main/java/org/saltyrtc/client/signaling/CloseCode.java#L90-L94

dbrgn commented 5 years ago

Hm, yeah, I think that's missing indeed! Good catch. The variable is only used in ValidationHelper.validateCloseCode, but it could still potentially result in an exception during teardown of the connection.

ovalseven8 commented 5 years ago

You can assign me if you want.

dbrgn commented 5 years ago

@ovalseven8 if you're up for a pull request, sure! That would be welcome.

Note: Adding a simple regression test for all valid close codes before adding the fix might be a good idea.