Re: All Your Thread Are Belong to Us
From: C# Learner (csharp_at_learner.here)
Date: 05/30/04
- Next message: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Previous message: Jon Skeet [C# MVP]: "Re: All Your Thread Are Belong to Us"
- In reply to: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Next in thread: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Reply: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Messages sorted by: [ date ] [ thread ]
Date: Sun, 30 May 2004 06:41:29 +0100
Daniel O'Connell [C# MVP] wrote:
> [...]
Hi Daniel,
Thanks for the reply -- it made me take a step back and think at a
higher level.
After several hours, I've finally fixed the two bugs that were causing
the problems.
The first bug was that I was calling ArrayList.Remove instead of
ArrayList.RemoveAt. I was passing an 'int' as a parameter to Remove,
when the ArrayList was holding only references to instances of class
Connection. Doh!
I'm kicking myself now because of this. What seems weird here, though,
is that ArrayList.Remove doesn't throw an exception when the passed
reference doesn't exist in the list.
The other bug was a race condition which I solved by locking a
particular block of code that I hadn't given enough prior thought to.
I appreciated your reply.
I'm gonna have to let my brain rest for awhile now.
See ya.
- Next message: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Previous message: Jon Skeet [C# MVP]: "Re: All Your Thread Are Belong to Us"
- In reply to: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Next in thread: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Reply: Daniel O'Connell [C# MVP]: "Re: All Your Thread Are Belong to Us"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|