Skip to content

Conversation

@saligrama
Copy link

Issue:

Currently, the data channel has several concurrent goroutines that modify shared data. When running under the Go race detector go run -race, multiple warnings are fired about data races pertaining to the data channel. Moreover, the session registry holds one live instance of each session type (shell / port), meaning that when using the plugin as a library and trying to open multiple sessions at a time, these sessions overwrite each other's data.

Description of changes:

  • Add locking to the data channel and locking where shared data is modified
  • Modify the session registry to store constructors of session types, rather than live session instances.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant