Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Posible concurrency problema #9

Open
gfazzola opened this issue Aug 28, 2015 · 0 comments
Open

Posible concurrency problema #9

gfazzola opened this issue Aug 28, 2015 · 0 comments

Comments

@gfazzola
Copy link

Hello Halil. I think I found a possible bug in the TcpCommunicationChannel SendMessageInternal class method.
The method begins with
// Send message
             totalSent var = 0;
             lock (_syncLock)
             {
.....

totalSent + = sent;
             }

The problem I see is that the variable totalSent is out of lock which if you were using several processes other could enter the method, initialize the variable to zero, modifying the value of the same that is used to complete the loop (below ....
totalSent + = sent;
)

I have not tested to confirm it but I think it is possible.

Greetings from Argentina!!

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

No branches or pull requests

1 participant