aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Taylor <rob.taylor@codethink.co.uk>2007-11-07 16:55:47 +0000
committerRob Taylor <rob.taylor@codethink.co.uk>2008-03-12 20:11:09 +0100
commit7bd703b8abb8252eae4002180852c492aa686d88 (patch)
treea71b2a38b16d30abe2d3a5b989b00e32115c98e2
parentdocument already existing pnp namespace in the spec (diff)
downloadgentoo-hal-7bd703b8abb8252eae4002180852c492aa686d88.tar.gz
gentoo-hal-7bd703b8abb8252eae4002180852c492aa686d88.tar.bz2
gentoo-hal-7bd703b8abb8252eae4002180852c492aa686d88.zip
use slices for HalProperty
Use g_slice for storing HalProperty. Reduces memory fragmentation during coldplug.
-rw-r--r--hald/device.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hald/device.c b/hald/device.c
index 304f177d..a0b99acf 100644
--- a/hald/device.c
+++ b/hald/device.c
@@ -80,14 +80,14 @@ hal_property_free (HalProperty *prop)
}
g_slist_free (prop->v.strlist_value);
}
- g_free (prop);
+ g_slice_free (HalProperty, prop);
}
static inline HalProperty *
hal_property_new (int type)
{
HalProperty *prop;
- prop = g_new0 (HalProperty, 1);
+ prop = g_slice_new0 (HalProperty);
prop->type = type;
return prop;
}