Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Dep/ACE: Fix assertion triggered on shutdown

Fix assertion triggered on shutdown on Windows platform Debug mode by back-porting fix from ACE revision 96226.
Fixes #9770.
  • Loading branch information...
commit e4ab18a69c677183a519393708bc5ce32fb38fcc 1 parent 3a40d8a
jackpoz jackpoz authored
Showing with 6 additions and 2 deletions.
  1. +6 −2 dep/acelite/ace/OS_NS_Thread.cpp
8 dep/acelite/ace/OS_NS_Thread.cpp
View
@@ -885,8 +885,12 @@ ACE_TSS_Cleanup::thread_detach_key (ACE_thread_key_t key)
ACE_TSS_CLEANUP_GUARD
u_int key_index = key;
- ACE_ASSERT (key_index < sizeof(this->table_)/sizeof(this->table_[0])
- && this->table_[key_index].key_ == key);
+ ACE_ASSERT (key_index < sizeof(this->table_)/sizeof(this->table_[0]));
+ // If this entry was never set, just bug out. If it is set, but is the
+ // wrong key, assert.
+ if (this->table_[key_index].key_ == 0)
+ return 0;
+ ACE_ASSERT(this->table_[key_index].key_ == key);
ACE_TSS_Info &info = this->table_ [key_index];
// sanity check

1 comment on commit e4ab18a

Maxxgold

@jackpoz
Works Great. Server shuts down with no errors in Debug Mode.

Please sign in to comment.
Something went wrong with that request. Please try again.