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
63b7d9d1
Commit
63b7d9d1
authored
Apr 29, 2017
by
Olivier Bertrand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix MDEV-12631 valgrind warning for zipped tables
modified: storage/connect/filamzip.cpp
parent
a091314d
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
4 deletions
+10
-4
storage/connect/filamzip.cpp
storage/connect/filamzip.cpp
+10
-4
No files found.
storage/connect/filamzip.cpp
View file @
63b7d9d1
/*********** File AM Zip C++ Program Source Code File (.CPP) ***********/
/* PROGRAM NAME: FILAMZIP */
/* ------------- */
/* Version 1.
1
*/
/* Version 1.
2
*/
/* */
/* COPYRIGHT: */
/* ---------- */
...
...
@@ -652,12 +652,18 @@ bool UNZIPUTL::openEntry(PGLOBAL g)
}
// endif rc
size
=
finfo
.
uncompressed_size
;
memory
=
new
char
[
size
+
1
];
try
{
memory
=
new
char
[
size
+
1
];
}
catch
(...)
{
strcpy
(
g
->
Message
,
"Out of memory"
);
return
true
;
}
// end try/catch
if
((
rc
=
unzReadCurrentFile
(
zipfile
,
memory
,
size
))
<
0
)
{
sprintf
(
g
->
Message
,
"unzReadCurrentFile rc = %d"
,
rc
);
unzCloseCurrentFile
(
zipfile
);
free
(
memory
)
;
delete
[]
memory
;
memory
=
NULL
;
entryopen
=
false
;
}
else
{
...
...
@@ -682,7 +688,7 @@ void UNZIPUTL::closeEntry()
}
// endif entryopen
if
(
memory
)
{
free
(
memory
)
;
delete
[]
memory
;
memory
=
NULL
;
}
// endif memory
...
...
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