Minor cleanup.

git-svn-id: file:///srv/svn/repos/haiku/trunk/current@10300 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Axel Dörfler
2004-11-30 17:46:37 +00:00
parent caa0ef0b4c
commit f4561860ac
@@ -1,7 +1,7 @@
/* /*
** Copyright 2002/03, Thomas Kurschel. All rights reserved. * Copyright 2002/03, Thomas Kurschel. All rights reserved.
** Distributed under the terms of the OpenBeOS License. * Distributed under the terms of the MIT License.
*/ */
/* /*
Deadlock-safe allocation of locked memory. Deadlock-safe allocation of locked memory.
@@ -480,8 +480,10 @@ err:
} }
// public: destroy pool /** public: destroy pool */
static void destroy_pool( locked_pool *pool )
static void
destroy_pool(locked_pool *pool)
{ {
TRACE(("destroy_pool()\n")); TRACE(("destroy_pool()\n"));
@@ -509,17 +511,17 @@ init_locked_pool(void)
{ {
status_t res; status_t res;
if ((res = benaphore_init(&locked_pool_ben, "locked_pool_global_list")) < 0) if ((res = benaphore_init(&locked_pool_ben, "locked_pool_global_list")) < B_OK)
goto err; goto err;
if ((res = locked_pool_enlarger_sem = create_sem(0, "locked_pool_enlarger")) < 0) if ((res = locked_pool_enlarger_sem = create_sem(0, "locked_pool_enlarger")) < B_OK)
goto err2; goto err2;
locked_pools = NULL; locked_pools = NULL;
locked_pool_shutting_down = false; locked_pool_shutting_down = false;
if ((res = locked_pool_enlarger_thread = spawn_kernel_thread(enlarger_threadproc, if ((res = locked_pool_enlarger_thread = spawn_kernel_thread(enlarger_threadproc,
"locked_pool_enlarger", B_NORMAL_PRIORITY, NULL)) < 0) "locked_pool_enlarger", B_NORMAL_PRIORITY, NULL)) < B_OK)
goto err3; goto err3;
resume_thread(locked_pool_enlarger_thread); resume_thread(locked_pool_enlarger_thread);
@@ -538,7 +540,7 @@ err:
/** global uninit, executed before module is unloaded */ /** global uninit, executed before module is unloaded */
static status_t static status_t
uninit_locked_pool() uninit_locked_pool(void)
{ {
int32 retcode; int32 retcode;
locked_pool_shutting_down = true; locked_pool_shutting_down = true;