This repository has been archived by the owner on Jul 8, 2020. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix for
passiveListenIP
. Currently the function returns different (#70
) formats depending if the value is retrieved from the underlying connection or from the value set by given parameters. If the value is taken from the parameters then the value is returned as it was set. If it is retrieved from the underlying connection, then `Addr.String()` is used which appends the port number. The code using the value returned from the function always assume that the format is `<ip>:<port`. Which is not the case for a listen ip set by the user. I decided to change the behavior and make `passiveListenIP` always return an IP address, as it names suggest. This fixes the issue and removed the need of checking for the format on the calling side.
- Loading branch information
Showing
3 changed files
with
68 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters