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
8a9c481e
Commit
8a9c481e
authored
Nov 28, 2006
by
brian@zim.(none)
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Varchar hack to clean strings removed.
parent
f175a892
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
21 deletions
+0
-21
storage/archive/ha_archive.cc
storage/archive/ha_archive.cc
+0
-21
No files found.
storage/archive/ha_archive.cc
View file @
8a9c481e
...
...
@@ -896,27 +896,6 @@ int ha_archive::write_row(byte *buf)
if
(
init_archive_writer
())
DBUG_RETURN
(
HA_ERR_CRASHED_ON_USAGE
);
/*
Varchar structures are constant in size but are not cleaned up request
to request. The following sets all unused space to null to improve
compression.
*/
for
(
Field
**
field
=
table
->
field
;
*
field
;
field
++
)
{
DBUG_PRINT
(
"archive"
,(
"Pack is %d
\n
"
,
(
*
field
)
->
pack_length
()));
DBUG_PRINT
(
"archive"
,(
"MyPack is %d
\n
"
,
(
*
field
)
->
data_length
((
char
*
)
buf
+
(
*
field
)
->
offset
(
record
))));
if
((
*
field
)
->
real_type
()
==
MYSQL_TYPE_VARCHAR
)
{
char
*
ptr
=
(
*
field
)
->
ptr
+
actual_length
;
DBUG_ASSERT
(
actual_length
<=
(
*
field
)
->
pack_length
());
uint32
to_free
=
(
*
field
)
->
pack_length
()
-
actual_length
;
if
(
to_free
>
0
)
bzero
(
ptr
,
to_free
);
}
}
share
->
rows_recorded
++
;
rc
=
real_write_row
(
buf
,
&
(
share
->
archive_write
));
error:
...
...
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