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
c2e04065
Commit
c2e04065
authored
Oct 26, 2004
by
heikki@hundin.mysql.fi
Browse files
Options
Browse Files
Download
Plain Diff
Merge heikki@bk-internal.mysql.com:/home/bk/mysql-4.1
into hundin.mysql.fi:/home/heikki/mysql-4.1
parents
9ec8e38e
a761a901
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
14 deletions
+50
-14
innobase/fil/fil0fil.c
innobase/fil/fil0fil.c
+14
-0
innobase/os/os0file.c
innobase/os/os0file.c
+11
-14
innobase/row/row0mysql.c
innobase/row/row0mysql.c
+25
-0
No files found.
innobase/fil/fil0fil.c
View file @
c2e04065
...
@@ -1868,6 +1868,10 @@ try_again:
...
@@ -1868,6 +1868,10 @@ try_again:
if
(
success
)
{
if
(
success
)
{
success
=
os_file_delete
(
path
);
success
=
os_file_delete
(
path
);
if
(
!
success
)
{
success
=
os_file_delete_if_exists
(
path
);
}
}
}
if
(
success
)
{
if
(
success
)
{
...
@@ -2366,6 +2370,16 @@ fil_reset_too_high_lsns(
...
@@ -2366,6 +2370,16 @@ fil_reset_too_high_lsns(
file
=
os_file_create_simple_no_error_handling
(
filepath
,
OS_FILE_OPEN
,
file
=
os_file_create_simple_no_error_handling
(
filepath
,
OS_FILE_OPEN
,
OS_FILE_READ_WRITE
,
&
success
);
OS_FILE_READ_WRITE
,
&
success
);
if
(
!
success
)
{
if
(
!
success
)
{
/* The following call prints an error message */
os_file_get_last_error
(
TRUE
);
ut_print_timestamp
(
stderr
);
fputs
(
" InnoDB: Error: trying to open a table, but could not
\n
"
"InnoDB: open the tablespace file "
,
stderr
);
ut_print_filename
(
stderr
,
filepath
);
fputs
(
"!
\n
"
,
stderr
);
mem_free
(
filepath
);
mem_free
(
filepath
);
return
(
FALSE
);
return
(
FALSE
);
...
...
innobase/os/os0file.c
View file @
c2e04065
...
@@ -410,14 +410,11 @@ os_file_handle_error_no_exit(
...
@@ -410,14 +410,11 @@ os_file_handle_error_no_exit(
/*=========================*/
/*=========================*/
/* out: TRUE if we should retry the
/* out: TRUE if we should retry the
operation */
operation */
os_file_t
file
,
/* in: file pointer */
const
char
*
name
,
/* in: name of a file or NULL */
const
char
*
name
,
/* in: name of a file or NULL */
const
char
*
operation
)
/* in: operation */
const
char
*
operation
)
/* in: operation */
{
{
ulint
err
;
ulint
err
;
UT_NOT_USED
(
file
);
err
=
os_file_get_last_error
(
FALSE
);
err
=
os_file_get_last_error
(
FALSE
);
if
(
err
==
OS_FILE_DISK_FULL
)
{
if
(
err
==
OS_FILE_DISK_FULL
)
{
...
@@ -624,7 +621,7 @@ os_file_closedir(
...
@@ -624,7 +621,7 @@ os_file_closedir(
ret
=
FindClose
(
dir
);
ret
=
FindClose
(
dir
);
if
(
!
ret
)
{
if
(
!
ret
)
{
os_file_handle_error_no_exit
(
NULL
,
NULL
,
"closedir"
);
os_file_handle_error_no_exit
(
NULL
,
"closedir"
);
return
(
-
1
);
return
(
-
1
);
}
}
...
@@ -636,7 +633,7 @@ os_file_closedir(
...
@@ -636,7 +633,7 @@ os_file_closedir(
ret
=
closedir
(
dir
);
ret
=
closedir
(
dir
);
if
(
ret
)
{
if
(
ret
)
{
os_file_handle_error_no_exit
(
0
,
NULL
,
"closedir"
);
os_file_handle_error_no_exit
(
NULL
,
"closedir"
);
}
}
return
(
ret
);
return
(
ret
);
...
@@ -705,7 +702,7 @@ http://www.mysql.com/doc/en/Windows_symbolic_links.html */
...
@@ -705,7 +702,7 @@ http://www.mysql.com/doc/en/Windows_symbolic_links.html */
return
(
1
);
return
(
1
);
}
else
{
}
else
{
os_file_handle_error_no_exit
(
NULL
,
dirname
,
os_file_handle_error_no_exit
(
dirname
,
"readdir_next_file"
);
"readdir_next_file"
);
return
(
-
1
);
return
(
-
1
);
}
}
...
@@ -737,7 +734,7 @@ next_file:
...
@@ -737,7 +734,7 @@ next_file:
ret
=
stat
(
full_path
,
&
statinfo
);
ret
=
stat
(
full_path
,
&
statinfo
);
if
(
ret
)
{
if
(
ret
)
{
os_file_handle_error_no_exit
(
0
,
full_path
,
"stat"
);
os_file_handle_error_no_exit
(
full_path
,
"stat"
);
ut_free
(
full_path
);
ut_free
(
full_path
);
...
@@ -1326,7 +1323,7 @@ loop:
...
@@ -1326,7 +1323,7 @@ loop:
ret
=
unlink
((
const
char
*
)
name
);
ret
=
unlink
((
const
char
*
)
name
);
if
(
ret
!=
0
&&
errno
!=
ENOENT
)
{
if
(
ret
!=
0
&&
errno
!=
ENOENT
)
{
os_file_handle_error
(
name
,
"delete"
);
os_file_handle_error
_no_exit
(
name
,
"delete"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
@@ -1388,7 +1385,7 @@ loop:
...
@@ -1388,7 +1385,7 @@ loop:
ret
=
unlink
((
const
char
*
)
name
);
ret
=
unlink
((
const
char
*
)
name
);
if
(
ret
!=
0
)
{
if
(
ret
!=
0
)
{
os_file_handle_error
(
name
,
"delete"
);
os_file_handle_error
_no_exit
(
name
,
"delete"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
@@ -2117,7 +2114,7 @@ try_again:
...
@@ -2117,7 +2114,7 @@ try_again:
#ifdef __WIN__
#ifdef __WIN__
error_handling:
error_handling:
#endif
#endif
retry
=
os_file_handle_error_no_exit
(
file
,
NULL
,
"read"
);
retry
=
os_file_handle_error_no_exit
(
NULL
,
"read"
);
if
(
retry
)
{
if
(
retry
)
{
goto
try_again
;
goto
try_again
;
...
@@ -2310,7 +2307,7 @@ os_file_status(
...
@@ -2310,7 +2307,7 @@ os_file_status(
}
else
if
(
ret
)
{
}
else
if
(
ret
)
{
/* file exists, but stat call failed */
/* file exists, but stat call failed */
os_file_handle_error_no_exit
(
0
,
path
,
"stat"
);
os_file_handle_error_no_exit
(
path
,
"stat"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
@@ -2338,7 +2335,7 @@ os_file_status(
...
@@ -2338,7 +2335,7 @@ os_file_status(
}
else
if
(
ret
)
{
}
else
if
(
ret
)
{
/* file exists, but stat call failed */
/* file exists, but stat call failed */
os_file_handle_error_no_exit
(
0
,
path
,
"stat"
);
os_file_handle_error_no_exit
(
path
,
"stat"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
@@ -2381,7 +2378,7 @@ os_file_get_status(
...
@@ -2381,7 +2378,7 @@ os_file_get_status(
}
else
if
(
ret
)
{
}
else
if
(
ret
)
{
/* file exists, but stat call failed */
/* file exists, but stat call failed */
os_file_handle_error_no_exit
(
0
,
path
,
"stat"
);
os_file_handle_error_no_exit
(
path
,
"stat"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
@@ -2412,7 +2409,7 @@ os_file_get_status(
...
@@ -2412,7 +2409,7 @@ os_file_get_status(
}
else
if
(
ret
)
{
}
else
if
(
ret
)
{
/* file exists, but stat call failed */
/* file exists, but stat call failed */
os_file_handle_error_no_exit
(
0
,
path
,
"stat"
);
os_file_handle_error_no_exit
(
path
,
"stat"
);
return
(
FALSE
);
return
(
FALSE
);
}
}
...
...
innobase/row/row0mysql.c
View file @
c2e04065
...
@@ -2153,6 +2153,12 @@ row_import_tablespace_for_mysql(
...
@@ -2153,6 +2153,12 @@ row_import_tablespace_for_mysql(
success
=
fil_reset_too_high_lsns
(
name
,
current_lsn
);
success
=
fil_reset_too_high_lsns
(
name
,
current_lsn
);
if
(
!
success
)
{
if
(
!
success
)
{
ut_print_timestamp
(
stderr
);
fputs
(
" InnoDB: Error: cannot reset lsn's in table "
,
stderr
);
ut_print_name
(
stderr
,
trx
,
name
);
fputs
(
"
\n
"
"InnoDB: in ALTER TABLE ... IMPORT TABLESPACE
\n
"
,
stderr
);
err
=
DB_ERROR
;
err
=
DB_ERROR
;
row_mysql_lock_data_dictionary
(
trx
);
row_mysql_lock_data_dictionary
(
trx
);
...
@@ -2168,6 +2174,14 @@ row_import_tablespace_for_mysql(
...
@@ -2168,6 +2174,14 @@ row_import_tablespace_for_mysql(
table
=
dict_table_get_low
(
name
);
table
=
dict_table_get_low
(
name
);
if
(
!
table
)
{
if
(
!
table
)
{
ut_print_timestamp
(
stderr
);
fputs
(
" InnoDB: table "
,
stderr
);
ut_print_name
(
stderr
,
trx
,
name
);
fputs
(
"
\n
"
"InnoDB: does not exist in the InnoDB data dictionary
\n
"
"InnoDB: in ALTER TABLE ... IMPORT TABLESPACE
\n
"
,
stderr
);
err
=
DB_TABLE_NOT_FOUND
;
err
=
DB_TABLE_NOT_FOUND
;
goto
funct_exit
;
goto
funct_exit
;
...
@@ -2209,6 +2223,17 @@ row_import_tablespace_for_mysql(
...
@@ -2209,6 +2223,17 @@ row_import_tablespace_for_mysql(
table
->
ibd_file_missing
=
FALSE
;
table
->
ibd_file_missing
=
FALSE
;
table
->
tablespace_discarded
=
FALSE
;
table
->
tablespace_discarded
=
FALSE
;
}
else
{
}
else
{
if
(
table
->
ibd_file_missing
)
{
ut_print_timestamp
(
stderr
);
fputs
(
" InnoDB: cannot find of open in the database directory the .ibd file of
\n
"
"InnoDB: table "
,
stderr
);
ut_print_name
(
stderr
,
trx
,
name
);
fputs
(
"
\n
"
"InnoDB: in ALTER TABLE ... IMPORT TABLESPACE
\n
"
,
stderr
);
}
err
=
DB_ERROR
;
err
=
DB_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