diff options
author | Martin Mares <mj@ucw.cz> | 1998-05-24 16:46:20 +0200 |
---|---|---|
committer | Martin Mares <mj@ucw.cz> | 1998-05-24 16:46:20 +0200 |
commit | d4bc8dc00037e868771fb259a1e7b9ae5e92ed5a (patch) | |
tree | a0e2b60de2823ce7c3fd1c3fa269d7fe8bcacfb9 /lib | |
parent | 315aba32b3c5744a040331d653218d15a55455a5 (diff) | |
download | bird-d4bc8dc00037e868771fb259a1e7b9ae5e92ed5a.tar bird-d4bc8dc00037e868771fb259a1e7b9ae5e92ed5a.zip |
Staticized some variables and functions.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/mempool.c | 2 | ||||
-rw-r--r-- | lib/resource.c | 14 | ||||
-rw-r--r-- | lib/slab.c | 10 |
3 files changed, 13 insertions, 13 deletions
diff --git a/lib/mempool.c b/lib/mempool.c index d2f2c09..8bf428e 100644 --- a/lib/mempool.c +++ b/lib/mempool.c @@ -27,7 +27,7 @@ struct mempool { void mp_free(resource *); void mp_dump(resource *); -struct resclass mp_class = { +static struct resclass mp_class = { "MemPool", sizeof(struct mempool), mp_free, diff --git a/lib/resource.c b/lib/resource.c index 2806a90..fe879cf 100644 --- a/lib/resource.c +++ b/lib/resource.c @@ -17,8 +17,8 @@ struct pool { list inside; }; -void pool_dump(resource *); -void pool_free(resource *); +static void pool_dump(resource *); +static void pool_free(resource *); static struct resclass pool_class = { "Pool", @@ -39,7 +39,7 @@ rp_new(pool *p) return z; } -void +static void pool_free(resource *P) { pool *p = (pool *) P; @@ -54,7 +54,7 @@ pool_free(resource *P) } } -void +static void pool_dump(resource *P) { pool *p = (pool *) P; @@ -125,18 +125,18 @@ struct mblock { byte data[0]; }; -void mbl_free(resource *r) +static void mbl_free(resource *r) { } -void mbl_debug(resource *r) +static void mbl_debug(resource *r) { struct mblock *m = (struct mblock *) r; debug("(size=%d)\n", m->size); } -struct resclass mb_class = { +static struct resclass mb_class = { "Memory", 0, mbl_free, @@ -27,10 +27,10 @@ struct slab { list objs; }; -void slab_free(resource *r); -void slab_dump(resource *r); +static void slab_free(resource *r); +static void slab_dump(resource *r); -struct resclass sl_class = { +static struct resclass sl_class = { "Slab", sizeof(struct slab), slab_free, @@ -64,7 +64,7 @@ sl_free(slab *s, void *oo) xfree(o); } -void +static void slab_free(resource *r) { slab *s = (slab *) r; @@ -74,7 +74,7 @@ slab_free(resource *r) xfree(o); } -void +static void slab_dump(resource *r) { slab *s = (slab *) r; |