Commit 519cef22 authored by Tom Lane's avatar Tom Lane

Add missing min/max parameters to DefineCustomIntVariable() and

DefineCustomRealVariable().  Thomas Hallgren
parent 6e26c002
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
* Written by Peter Eisentraut <peter_e@gmx.net>. * Written by Peter Eisentraut <peter_e@gmx.net>.
* *
* IDENTIFICATION * IDENTIFICATION
* $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.256 2005/03/19 23:27:07 tgl Exp $ * $PostgreSQL: pgsql/src/backend/utils/misc/guc.c,v 1.257 2005/03/25 16:17:27 tgl Exp $
* *
*-------------------------------------------------------------------- *--------------------------------------------------------------------
*/ */
...@@ -4187,6 +4187,8 @@ DefineCustomIntVariable( ...@@ -4187,6 +4187,8 @@ DefineCustomIntVariable(
const char *short_desc, const char *short_desc,
const char *long_desc, const char *long_desc,
int *valueAddr, int *valueAddr,
int minValue,
int maxValue,
GucContext context, GucContext context,
GucIntAssignHook assign_hook, GucIntAssignHook assign_hook,
GucShowHook show_hook) GucShowHook show_hook)
...@@ -4199,6 +4201,8 @@ DefineCustomIntVariable( ...@@ -4199,6 +4201,8 @@ DefineCustomIntVariable(
var->variable = valueAddr; var->variable = valueAddr;
var->reset_val = *valueAddr; var->reset_val = *valueAddr;
var->min = minValue;
var->max = maxValue;
var->assign_hook = assign_hook; var->assign_hook = assign_hook;
var->show_hook = show_hook; var->show_hook = show_hook;
define_custom_variable(&var->gen); define_custom_variable(&var->gen);
...@@ -4210,6 +4214,8 @@ DefineCustomRealVariable( ...@@ -4210,6 +4214,8 @@ DefineCustomRealVariable(
const char *short_desc, const char *short_desc,
const char *long_desc, const char *long_desc,
double *valueAddr, double *valueAddr,
double minValue,
double maxValue,
GucContext context, GucContext context,
GucRealAssignHook assign_hook, GucRealAssignHook assign_hook,
GucShowHook show_hook) GucShowHook show_hook)
...@@ -4222,6 +4228,8 @@ DefineCustomRealVariable( ...@@ -4222,6 +4228,8 @@ DefineCustomRealVariable(
var->variable = valueAddr; var->variable = valueAddr;
var->reset_val = *valueAddr; var->reset_val = *valueAddr;
var->min = minValue;
var->max = maxValue;
var->assign_hook = assign_hook; var->assign_hook = assign_hook;
var->show_hook = show_hook; var->show_hook = show_hook;
define_custom_variable(&var->gen); define_custom_variable(&var->gen);
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* Copyright (c) 2000-2005, PostgreSQL Global Development Group * Copyright (c) 2000-2005, PostgreSQL Global Development Group
* Written by Peter Eisentraut <peter_e@gmx.net>. * Written by Peter Eisentraut <peter_e@gmx.net>.
* *
* $PostgreSQL: pgsql/src/include/utils/guc.h,v 1.59 2005/03/19 23:27:11 tgl Exp $ * $PostgreSQL: pgsql/src/include/utils/guc.h,v 1.60 2005/03/25 16:17:28 tgl Exp $
*-------------------------------------------------------------------- *--------------------------------------------------------------------
*/ */
#ifndef GUC_H #ifndef GUC_H
...@@ -151,6 +151,8 @@ extern void DefineCustomIntVariable( ...@@ -151,6 +151,8 @@ extern void DefineCustomIntVariable(
const char *short_desc, const char *short_desc,
const char *long_desc, const char *long_desc,
int *valueAddr, int *valueAddr,
int minValue,
int maxValue,
GucContext context, GucContext context,
GucIntAssignHook assign_hook, GucIntAssignHook assign_hook,
GucShowHook show_hook); GucShowHook show_hook);
...@@ -160,6 +162,8 @@ extern void DefineCustomRealVariable( ...@@ -160,6 +162,8 @@ extern void DefineCustomRealVariable(
const char *short_desc, const char *short_desc,
const char *long_desc, const char *long_desc,
double *valueAddr, double *valueAddr,
double minValue,
double maxValue,
GucContext context, GucContext context,
GucRealAssignHook assign_hook, GucRealAssignHook assign_hook,
GucShowHook show_hook); GucShowHook show_hook);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment