Commit e19986a4 authored by Ge Jun's avatar Ge Jun

suppress a warning on casting null to char*

parent c0fd4404
...@@ -132,7 +132,7 @@ void deallocate_stack_storage(StackStorage* s) { ...@@ -132,7 +132,7 @@ void deallocate_stack_storage(StackStorage* s) {
VALGRIND_STACK_DEREGISTER(s->valgrind_stack_id); VALGRIND_STACK_DEREGISTER(s->valgrind_stack_id);
} }
const int memsize = s->stacksize + s->guardsize; const int memsize = s->stacksize + s->guardsize;
if ((char*)s->bottom <= (char*)NULL + memsize) { if ((uintptr_t)s->bottom <= (uintptr_t)memsize) {
return; return;
} }
s_stack_count.fetch_sub(1, butil::memory_order_relaxed); s_stack_count.fetch_sub(1, butil::memory_order_relaxed);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment