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
3f19dfed
Commit
3f19dfed
authored
Mar 12, 2012
by
Vladislav Vaintroub
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
LP952607: Do not show MySQL services preinstalled by Dell in the upgrade wizard
parent
ea3ffc7f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
1 deletion
+38
-1
sql/winservice.c
sql/winservice.c
+38
-1
No files found.
sql/winservice.c
View file @
3f19dfed
...
...
@@ -58,6 +58,41 @@ void normalize_path(char *path, size_t size)
strcpy_s
(
path
,
size
,
buf
);
}
/*
Exclusion rules.
Some hardware manufacturers deliver systems with own preinstalled MySQL copy
and services. We do not want to mess up with these installations. We will
just ignore such services, pretending it is not MySQL.
@return
TRUE, if this service should be excluded from UI lists etc (OEM install)
FALSE otherwise.
*/
BOOL
exclude_service
(
mysqld_service_properties
*
props
)
{
static
const
char
*
exclude_patterns
[]
=
{
"common files
\\
dell
\\
mysql
\\
bin
\\
"
,
/* Dell's private installation */
NULL
};
int
i
;
char
buf
[
MAX_PATH
];
/* Convert mysqld path to lower case, rules for paths are case-insensitive. */
memcpy
(
buf
,
props
->
mysqld_exe
,
sizeof
(
props
->
mysqld_exe
));
_strlwr
(
buf
);
for
(
i
=
0
;
exclude_patterns
[
i
];
i
++
)
{
if
(
strstr
(
buf
,
exclude_patterns
[
i
]))
return
TRUE
;
}
return
FALSE
;
}
/*
Retrieve some properties from windows mysqld service binary path.
We're interested in ini file location and datadir, and also in version of
...
...
@@ -240,7 +275,9 @@ int get_mysql_service_properties(const wchar_t *bin_path,
}
}
}
retval
=
0
;
if
(
!
exclude_service
(
props
))
retval
=
0
;
end:
LocalFree
((
HLOCAL
)
args
);
return
retval
;
...
...
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