From 5557d2a224c2fc8ee9c66ceb7f66faf5a5ec44d2 Mon Sep 17 00:00:00 2001 From: rubidium Date: Thu, 17 Sep 2009 21:45:47 +0000 Subject: [PATCH] (svn r17563) -Fix: memory leak when viewing the NewGRF settings of a server --- src/newgrf_config.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/newgrf_config.cpp b/src/newgrf_config.cpp index aff7ac4066..655010244c 100644 --- a/src/newgrf_config.cpp +++ b/src/newgrf_config.cpp @@ -150,6 +150,8 @@ GRFConfig **CopyGRFConfigList(GRFConfig **dst, const GRFConfig *src, bool init_o if (src->error->custom_message != NULL) c->error->custom_message = strdup(src->error->custom_message); } + ClrBit(c->flags, GCF_COPY); + ClrBit(c->flags, GCF_INIT_ONLY); if (init_only) SetBit(c->flags, GCF_INIT_ONLY);