Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
RemoteFile leak fix and simplification
RemoteFile::Open() would leak file descriptors if Open() was explicitly called again after passing a url to the contructor which itself called Open(). This commit does several things: - Moves Open() private since RemoteFile users shouldn't need to Open() - Moves Close() private since there's no need to Close() if you can't Open(). Close() is already called in the destructor. - Convert the remaining uses of Open() to isOpen() since the connection is already opened in all these cases. - Remove a few Close() uses since they were were redundant since we already Close() in the destructor. - Removes unused SetURL() functionality. If you can't Open() or Close(), then you need to pass the URL in to the constructor so there's no need. - Fixes the actual leak in Open() by checking to see if the sockets are already open. Just in case.... Closes #11341. NOTE: This does modify the binary ABI version number due to the remotefile.h changes, so make clean, etc..
- Loading branch information
Showing
5 changed files
with
9 additions
and
9 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
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