summaryrefslogtreecommitdiff
path: root/innobase
diff options
context:
space:
mode:
authorunknown <heikki@donna.mysql.fi>2001-03-02 19:07:29 +0200
committerunknown <heikki@donna.mysql.fi>2001-03-02 19:07:29 +0200
commit3be063eab8cc9af4f7782b693b497817c2511ddc (patch)
treee096bcefe8539963540359f715bb58acff391647 /innobase
parente6a57adc935301833372ac9f13184e7b3b8d7d99 (diff)
downloadmariadb-git-3be063eab8cc9af4f7782b693b497817c2511ddc.tar.gz
row0sel.c Removes now trailing spaces from varchars
srv0start.c Removes now trailing spaces from varchars row0mysql.ic Removes now trailing spaces from varchars ha_innobase.cc Removes now trailing spaces from varchars sql/ha_innobase.cc: Removes now trailing spaces from varchars innobase/include/row0mysql.ic: Removes now trailing spaces from varchars innobase/row/row0sel.c: Removes now trailing spaces from varchars innobase/srv/srv0start.c: Removes now trailing spaces from varchars
Diffstat (limited to 'innobase')
-rw-r--r--innobase/include/row0mysql.ic7
-rw-r--r--innobase/row/row0sel.c3
-rw-r--r--innobase/srv/srv0start.c6
3 files changed, 15 insertions, 1 deletions
diff --git a/innobase/include/row0mysql.ic b/innobase/include/row0mysql.ic
index 957a143008d..6096e5771f7 100644
--- a/innobase/include/row0mysql.ic
+++ b/innobase/include/row0mysql.ic
@@ -89,7 +89,12 @@ row_mysql_store_col_in_innobase_format(
}
} else if (type == DATA_VARCHAR || type == DATA_VARMYSQL
|| type == DATA_BINARY) {
- ptr = row_mysql_read_var_ref(&col_len, mysql_data);
+ ptr = row_mysql_read_var_ref(&col_len, mysql_data);
+
+ /* Remove trailing spaces */
+ while (col_len > 0 && ptr[col_len - 1] == ' ') {
+ col_len--;
+ }
} else if (type == DATA_BLOB) {
ptr = row_mysql_read_blob_ref(&col_len, mysql_data, col_len);
diff --git a/innobase/row/row0sel.c b/innobase/row/row0sel.c
index 1045c39248e..e6182257581 100644
--- a/innobase/row/row0sel.c
+++ b/innobase/row/row0sel.c
@@ -1934,6 +1934,9 @@ row_sel_field_store_in_mysql_format(
dest = row_mysql_store_var_len(dest, len);
ut_memcpy(dest, data, len);
+ /* Pad with trailing spaces */
+ memset(dest + len, ' ', col_len - len);
+
/* ut_ad(col_len >= len + 2); No real var implemented in
MySQL yet! */
diff --git a/innobase/srv/srv0start.c b/innobase/srv/srv0start.c
index a051e2b62b5..b57558859b2 100644
--- a/innobase/srv/srv0start.c
+++ b/innobase/srv/srv0start.c
@@ -175,6 +175,9 @@ open_or_create_log_file(
fprintf(stderr,
"Innobase: Log file %s did not exist: new to be created\n",
name);
+ printf("Innobase: Setting log file %s size to %lu\n",
+ name, UNIV_PAGE_SIZE * srv_log_file_size);
+
ret = os_file_set_size(name, files[i],
UNIV_PAGE_SIZE * srv_log_file_size, 0);
if (!ret) {
@@ -323,6 +326,9 @@ open_or_create_data_files(
printf("Innobase: Setting file %s size to %lu\n",
name, UNIV_PAGE_SIZE * srv_data_file_sizes[i]);
+ printf(
+ "Innobase: Database physically writes the file full: wait...\n");
+
ret = os_file_set_size(name, files[i],
UNIV_PAGE_SIZE * srv_data_file_sizes[i], 0);