summaryrefslogtreecommitdiff
path: root/mysys/my_getopt.c
diff options
context:
space:
mode:
Diffstat (limited to 'mysys/my_getopt.c')
-rw-r--r--mysys/my_getopt.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/mysys/my_getopt.c b/mysys/my_getopt.c
index 48174a40c21..4b74cdbf266 100644
--- a/mysys/my_getopt.c
+++ b/mysys/my_getopt.c
@@ -846,7 +846,8 @@ longlong getopt_ll_limit_value(longlong num, const struct my_option *optp,
if (num < optp->min_value)
{
num= optp->min_value;
- adjusted= TRUE;
+ if (old < optp->min_value)
+ adjusted= TRUE;
}
if (fix)
@@ -917,7 +918,8 @@ ulonglong getopt_ull_limit_value(ulonglong num, const struct my_option *optp,
if (num < (ulonglong) optp->min_value)
{
num= (ulonglong) optp->min_value;
- adjusted= TRUE;
+ if (old < (ulonglong) optp->min_value)
+ adjusted= TRUE;
}
if (fix)