Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
d99fbf48
Commit
d99fbf48
authored
Feb 03, 2011
by
Vladislav Vaintroub
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MWL#55 : Add banner text to command line utilities
(Philip's review)
parent
3cb88652
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
8 deletions
+23
-8
sql/mysql_install_db.cc
sql/mysql_install_db.cc
+7
-0
sql/mysql_upgrade_service.cc
sql/mysql_upgrade_service.cc
+16
-8
No files found.
sql/mysql_install_db.cc
View file @
d99fbf48
...
...
@@ -13,6 +13,12 @@
#include <accctrl.h>
#include <aclapi.h>
#define USAGETEXT \
"mysql_install_db.exe Ver 1.42 for Windows\n" \
"This software comes with ABSOLUTELY NO WARRANTY. This is free software,
\n
"
\
"and you are welcome to modify and redistribute it under the GPL v2 license
\n
"
\
"Usage: mysql_install_db.exe [OPTIONS]
\n
"
\
"OPTIONS:"
extern
"C"
const
char
mysql_bootstrap_sql
[];
...
...
@@ -69,6 +75,7 @@ get_one_option(int optid,
DBUG_ENTER
(
"get_one_option"
);
switch
(
optid
)
{
case
'?'
:
printf
(
"%s
\n
"
,
USAGETEXT
);
my_print_help
(
my_long_options
);
exit
(
0
);
break
;
...
...
sql/mysql_upgrade_service.cc
View file @
d99fbf48
...
...
@@ -35,6 +35,13 @@
/* We're using version APIs */
#pragma comment(lib, "version")
#define USAGETEXT \
"mysql_upgrade_service.exe Ver 1.42 for Windows\n" \
"This software comes with ABSOLUTELY NO WARRANTY. This is free software,
\n
"
\
"and you are welcome to modify and redistribute it under the GPL v2 license
\n
"
\
"Usage: mysql_upgrade_service.exe [OPTIONS]
\n
"
\
"OPTIONS:"
static
char
mysqld_path
[
MAX_PATH
];
static
char
mysqladmin_path
[
MAX_PATH
];
static
char
mysqlupgrade_path
[
MAX_PATH
];
...
...
@@ -73,6 +80,7 @@ get_one_option(int optid,
DBUG_ENTER
(
"get_one_option"
);
switch
(
optid
)
{
case
'?'
:
printf
(
"%s
\n
"
,
USAGETEXT
);
my_print_help
(
my_long_options
);
exit
(
0
);
break
;
...
...
@@ -410,7 +418,13 @@ int main(int argc, char **argv)
char
bindir
[
FN_REFLEN
];
char
*
p
;
/*
/* Parse options */
if
((
error
=
handle_options
(
&
argc
,
&
argv
,
my_long_options
,
get_one_option
)))
die
(
""
);
if
(
!
opt_service
)
die
(
"service parameter is mandatory"
);
/*
Get full path to mysqld, we need it when changing service configuration.
Assume installation layout, i.e mysqld.exe, mysqladmin.exe, mysqlupgrade.exe
and mysql_upgrade_service.exe are in the same directory.
...
...
@@ -432,13 +446,6 @@ int main(int argc, char **argv)
die
(
"File %s does not exist"
,
paths
[
i
]);
}
/* Parse options */
if
((
error
=
handle_options
(
&
argc
,
&
argv
,
my_long_options
,
get_one_option
)))
die
(
""
);
if
(
!
opt_service
)
die
(
"service parameter is mandatory"
);
/*
Messages written on stdout should not be buffered, GUI upgrade program
read them from pipe and uses as progress indicator.
...
...
@@ -451,6 +458,7 @@ int main(int argc, char **argv)
log
(
"Phase 2/8: Stopping service"
);
stop_mysqld_service
();
/*
Start mysqld.exe as non-service skipping privileges (so we do not
care about the password). But disable networking and enable pipe
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment