From b9bbe0a3368d69ecc3bcb22a3d658654aa2a42d5 Mon Sep 17 00:00:00 2001 From: Joshua Root Date: Sat, 5 Oct 2024 06:28:12 +1000 Subject: [PATCH] delete_reg: don't vacuum or checkpoint This gets run every time a trace thread is destroyed, which can be once per target. (That could probably be more efficient, but nonetheless it can be expected to happen multiple times in one port(1) command.) Well-behaved API clients will call mportshutdown just before exiting, which will cause these things to happen once as intended. (cherry picked from commit 804340d0443942c4d843b2d42eb8679b35203432) --- src/registry2.0/registry.c | 8 -------- 1 file changed, 8 deletions(-) diff --git a/src/registry2.0/registry.c b/src/registry2.0/registry.c index de6dbcf5d1..e9a6e1a649 100644 --- a/src/registry2.0/registry.c +++ b/src/registry2.0/registry.c @@ -146,14 +146,6 @@ static void delete_reg(ClientData reg, Tcl_Interp* interp) { fprintf(stderr, "reg_optimize: %s\n", error.description); reg_error_destruct(&error); } - if (Tcl_GetAssocData(interp, "registry::needs_vacuum", NULL) != NULL) { - reg_vacuum(Tcl_GetAssocData(interp, "registry::db_path", NULL)); - Tcl_DeleteAssocData(interp, "registry::needs_vacuum"); - } - if (reg_checkpoint((reg_registry*)reg, &error) == 0) { - fprintf(stderr, "reg_checkpoint: %s\n", error.description); - reg_error_destruct(&error); - } if (!registry_tcl_detach(interp, (reg_registry*)reg, &error)) { fprintf(stderr, "registry_tcl_detach: %s", error.description); reg_error_destruct(&error);