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
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
98ddf74d
Commit
98ddf74d
authored
Jun 22, 2005
by
reggie@mdk10.(none)
Browse files
Options
Browse Files
Download
Plain Diff
Merge mdk10.(none):/home/reggie/bk/bug9148
into mdk10.(none):/home/reggie/bk/mysql-5.0-base
parents
4ddc13af
70599271
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
5 deletions
+7
-5
mysys/my_access.c
mysys/my_access.c
+7
-5
No files found.
mysys/my_access.c
View file @
98ddf74d
...
...
@@ -93,18 +93,20 @@ int check_if_legal_filename(const char *path)
path
+=
dirname_length
(
path
);
/* To start of filename */
if
(
!
(
end
=
strchr
(
path
,
FN_EXTCHAR
)))
end
=
strend
(
path
);
if
(
path
==
end
||
(
uint
)
(
path
-
end
)
>
MAX_RESERVED_NAME_LENGTH
)
if
(
path
==
end
||
(
uint
)
(
end
-
path
)
>
MAX_RESERVED_NAME_LENGTH
)
DBUG_RETURN
(
0
);
/* Simplify inner loop */
for
(
reserved_name
=
reserved_names
;
*
reserved_name
;
reserved_name
++
)
{
const
char
*
name
=
path
;
while
(
name
!=
end
)
const
char
*
current_reserved_name
=
*
reserved_name
;
while
(
name
!=
end
&&
*
current_reserved_name
)
{
if
(
my_toupper
(
&
my_charset_latin1
,
*
path
)
!=
my_toupper
(
&
my_charset_latin1
,
*
name
))
if
(
*
current_reserved_name
!=
my_toupper
(
&
my_charset_latin1
,
*
name
))
break
;
if
(
name
++
==
end
)
current_reserved_name
++
;
if
(
++
name
==
end
)
DBUG_RETURN
(
1
);
/* Found wrong path */
}
}
...
...
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