summaryrefslogtreecommitdiff
path: root/extra
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2005-02-22 15:47:00 +0200
committerunknown <monty@mysql.com>2005-02-22 15:47:00 +0200
commitce99d4430f71a0e83298e67f2e33b660630c715d (patch)
tree775f6aaae95a3574b8d285d2433c3797b653e482 /extra
parent6965e72bd07874efee8ff6f94ab664533fc422e0 (diff)
parent2ae6eb094bb02a3e41ab611c9e9f27982a2ef9c3 (diff)
downloadmariadb-git-ce99d4430f71a0e83298e67f2e33b660630c715d.tar.gz
Merge with 4.1
BitKeeper/etc/logging_ok: auto-union client/mysql.cc: Auto merged extra/my_print_defaults.c: Auto merged include/m_string.h: Auto merged mysql-test/mysql-test-run.sh: Auto merged mysql-test/r/ctype_utf8.result: Auto merged mysql-test/r/user_var.result: Auto merged mysql-test/t/user_var.test: Auto merged scripts/make_binary_distribution.sh: Auto merged sql/item_func.cc: Auto merged sql/sql_yacc.yy: Auto merged strings/ctype-simple.c: Auto merged strings/ctype-ucs2.c: Auto merged strings/ctype-utf8.c: Auto merged libmysql/libmysql.c: ul mysql-test/r/ps_1general.result: Merge mysql-test/t/derived.test: Merge mysql-test/t/ps_1general.test: Merge mysql-test/t/type_float.test: Merge sql/field.cc: ul sql/item.cc: ul sql/item.h: ul sql/item_func.h: ul sql/item_strfunc.cc: ul sql/item_sum.cc: ul sql/item_sum.h: ul sql/procedure.h: ul sql/sql_derived.cc: Trivial merge sql/sql_parse.cc: ul sql/sql_update.cc: Trivial merge strings/strtod.c: Use updated code from 4.1 This is bascily same code as we had before or 5.0, execpt that we now have higher accuracy for floating points value that are integers (like 123.45E+02)
Diffstat (limited to 'extra')
-rw-r--r--extra/my_print_defaults.c18
1 files changed, 13 insertions, 5 deletions
diff --git a/extra/my_print_defaults.c b/extra/my_print_defaults.c
index 2ec6f8b406f..d5836cb0dc8 100644
--- a/extra/my_print_defaults.c
+++ b/extra/my_print_defaults.c
@@ -120,25 +120,33 @@ int main(int argc, char **argv)
int count, error;
char **load_default_groups, *tmp_arguments[2],
**argument, **arguments;
+ char *defaults, *extra_defaults;
MY_INIT(argv[0]);
+ get_defaults_files(argc, argv, &defaults, &extra_defaults);
+
/*
** Check out the args
*/
- if (get_options(&argc,&argv))
- exit(1);
if (!(load_default_groups=(char**) my_malloc((argc+2)*sizeof(char*),
MYF(MY_WME))))
exit(1);
+ if (get_options(&argc,&argv))
+ exit(1);
for (count=0; *argv ; argv++,count++)
load_default_groups[count]= *argv;
load_default_groups[count]=0;
- count=1;
+ count=0;
arguments=tmp_arguments;
- arguments[0]=my_progname;
- arguments[1]=0;
+ arguments[count++]=my_progname;
+ if (extra_defaults)
+ arguments[count++]= extra_defaults;
+ if (defaults)
+ arguments[count++]= defaults;
+ arguments[count]= 0;
+
if ((error= load_defaults(config_file, (const char **) load_default_groups,
&count, &arguments)))
{