From 411ae73283f2479544fe687d196910e809ad83b0 Mon Sep 17 00:00:00 2001 From: Michael Adam Date: Tue, 29 Apr 2008 15:30:45 +0200 Subject: registry: combine talloc_strdup() and normalize_reg_path() in regdb_fetch_keys(). the talloc_strdup() call is just and extra allocation here. Michael (This used to be commit 217233349b2d98d2506fcca47858373150e89924) --- source3/registry/reg_backend_db.c | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) (limited to 'source3/registry/reg_backend_db.c') diff --git a/source3/registry/reg_backend_db.c b/source3/registry/reg_backend_db.c index 6bd8d375fb..31ada0c85c 100644 --- a/source3/registry/reg_backend_db.c +++ b/source3/registry/reg_backend_db.c @@ -733,13 +733,7 @@ int regdb_fetch_keys(const char *key, REGSUBKEY_CTR *ctr) DEBUG(11,("regdb_fetch_keys: Enter key => [%s]\n", key ? key : "NULL")); - path = talloc_strdup(frame, key); - if (!path) { - goto fail; - } - - /* convert to key format */ - path = normalize_reg_path(frame, path); + path = normalize_reg_path(frame, key); if (!path) { goto fail; } -- cgit