You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hawq.apache.org by zt...@apache.org on 2022/09/01 14:19:37 UTC

[hawq] branch master updated: HAWQ-1846. fix core when reset non exist guc

This is an automated email from the ASF dual-hosted git repository.

ztao1987 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hawq.git


The following commit(s) were added to refs/heads/master by this push:
     new 357a2c5ea HAWQ-1846. fix core when reset non exist guc
357a2c5ea is described below

commit 357a2c5eae59cc834ae2b5eb1ba09ec8e4deacdc
Author: ztao1987 <zh...@gmail.com>
AuthorDate: Thu Sep 1 22:19:04 2022 +0800

    HAWQ-1846. fix core when reset non exist guc
---
 src/backend/utils/misc/guc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c
index cf98f22bc..4cd84ab42 100644
--- a/src/backend/utils/misc/guc.c
+++ b/src/backend/utils/misc/guc.c
@@ -11800,9 +11800,9 @@ bool ResetPGVariable(const char *name) {
     shouldDispatch = true;
   } else {
     struct config_generic *record = find_option(name, ERROR);
-    if (record->flags & (GUC_GPDB_ADDOPT | GUC_NEW_DISP)) shouldDispatch = true;
     set_config_option(name, NULL, (superuser() ? PGC_SUSET : PGC_USERSET),
                       PGC_S_SESSION, false, true);
+    if (record->flags & (GUC_GPDB_ADDOPT | GUC_NEW_DISP)) shouldDispatch = true;
   }
   return shouldDispatch;
 }