Opened 17 years ago
Closed 17 years ago
#2048 closed bug (invalid)
get_team_info() does not work properly
Reported by: | mmadia | Owned by: | axeld |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | - General | Version: | R1/pre-alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | #2999 | |
Platform: | All |
Description
the function get_team_info() is used by im_kit's im_server, specifically in Server::UnloadAddons()
im_kit's svn: http://www.beclan.org/svn/repos/imkit/server/im_server.cpp code snippet:
while (info.thread_count > (protoCount + 1)) {
get_team_info(info.team, &info); snooze(20000);
}
Change History (5)
comment:1 by , 17 years ago
comment:2 by , 17 years ago
Did you test if the preceding code breaks correctly when (or, if, at all) it finds the im_server (on haiku) ?
comment:3 by , 17 years ago
Note the code preceding it is incorrect (it searches for name ending with im_server), as "strace im_server" would come first in the process list. But fixing it still showed a wrong behaviour (it returned 6 while there was still only 1 thread last I tested). I worked around in the version I have, an tried to make a test case, but they seemed to work ok (before spawning a thread, after, after terminating it, ... seems consistent).
comment:4 by , 17 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
Are you sure the problem is get_team_info()? It really doesn't look like this is the case. num_threads seems to be correctly maintained, as does the team_info::id field.
Besides, this code looks broken to me, anyway, as it makes assumptions on the number of running threads that it cannot possibly know as it's implementation dependent - please fix your app.
comment:5 by , 16 years ago
Blocking: | 2999 added |
---|
(In #2999) No need to, I just mark this as a duplicate.
the observed behavior: im_server fails to load any protocols.