summaryrefslogtreecommitdiff
path: root/src/libsystemd-bus
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-04-11 18:58:45 -0400
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-04-12 19:26:12 -0400
commit2244a6fbe6012924e74c7f2197512a55e9238b05 (patch)
tree4ed9c206c3bcffc0fcd4d467f3f4b914b34cac5b /src/libsystemd-bus
parent2da833ac2d91abc6b4e3fa613b7eebbaba76144a (diff)
util: add wrapper for realloc to avoid specyfing type
Diffstat (limited to 'src/libsystemd-bus')
-rw-r--r--src/libsystemd-bus/bus-match.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/libsystemd-bus/bus-match.c b/src/libsystemd-bus/bus-match.c
index fed25c1a2a..37e7cc71f3 100644
--- a/src/libsystemd-bus/bus-match.c
+++ b/src/libsystemd-bus/bus-match.c
@@ -725,7 +725,7 @@ static int parse_match(
}
}
- if (!greedy_realloc((void**) &value, &value_allocated, j + 2)) {
+ if (!GREEDY_REALLOC(value, value_allocated, j + 2)) {
r = -ENOMEM;
goto fail;
}
@@ -744,8 +744,7 @@ static int parse_match(
} else
u = 0;
- if (!greedy_realloc((void**) &components, &components_allocated,
- (n_components + 1) * sizeof(struct match_component))) {
+ if (!GREEDY_REALLOC(components, components_allocated, n_components + 1)) {
r = -ENOMEM;
goto fail;
}