Commit 7910ce77 authored by unknown's avatar unknown

srv0start.c:

  Work around the AIX 5.1 ML7 patch problem in errno at a higher level, in srv0start.c
os0file.c:
  Revert the AIX patch here


innobase/os/os0file.c:
  Revert the AIX patch here
innobase/srv/srv0start.c:
  Work around the AIX 5.1 ML7 patch problem in errno at a higher level, in srv0start.c
parent c7c8f25f
......@@ -291,15 +291,6 @@ os_file_get_last_error(void)
return(OS_FILE_NOT_FOUND);
} else if (err == EEXIST) {
return(OS_FILE_ALREADY_EXISTS);
#ifdef UNIV_AIX
} else if (err == 0) {
fprintf(stderr,
"InnoDB: errno is 0. Since AIX 5.1 after security patch ML7 erroneously\n"
"InnoDB: sets errno to 0 when it should be EEXIST, we assume that the real\n"
"InnoDB: error here was EEXIST.\n");
return(OS_FILE_ALREADY_EXISTS);
#endif
} else {
return(100 + err);
}
......
......@@ -540,7 +540,14 @@ open_or_create_log_file(
files[i] = os_file_create(name, OS_FILE_CREATE, OS_FILE_NORMAL,
OS_LOG_FILE, &ret);
if (ret == FALSE) {
if (os_file_get_last_error() != OS_FILE_ALREADY_EXISTS) {
if (os_file_get_last_error() != OS_FILE_ALREADY_EXISTS
#ifdef UNIV_AIX
/* AIX 5.1 after security patch ML7 may have errno set
to 0 here, which causes our function to return 100;
work around that AIX problem */
&& os_file_get_last_error() != 100
#endif
) {
fprintf(stderr,
"InnoDB: Error in creating or opening %s\n", name);
......@@ -712,7 +719,15 @@ open_or_create_data_files(
if (ret == FALSE) {
if (srv_data_file_is_raw_partition[i] != SRV_OLD_RAW
&& os_file_get_last_error() !=
OS_FILE_ALREADY_EXISTS) {
OS_FILE_ALREADY_EXISTS
#ifdef UNIV_AIX
/* AIX 5.1 after security patch ML7 may have
errno set to 0 here, which causes our function
to return 100; work around that AIX problem */
&& os_file_get_last_error() != 100
#endif
) {
fprintf(stderr,
"InnoDB: Error in creating or opening %s\n",
name);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment