summaryrefslogtreecommitdiff
path: root/innobase/ut
diff options
context:
space:
mode:
authorunknown <heikki@hundin.mysql.fi>2003-02-24 16:05:54 +0200
committerunknown <heikki@hundin.mysql.fi>2003-02-24 16:05:54 +0200
commitb5679828cf062107c9d6092c1044eef7965bca72 (patch)
treee333e6ee22cd280aaf3999f1aa34c7ade16f9bea /innobase/ut
parent13626f52c3ceb2fd630b987b502f013709b1a4ce (diff)
downloadmariadb-git-b5679828cf062107c9d6092c1044eef7965bca72.tar.gz
ut0mem.c:
Print correct OS error number also on Windows if we run out of memory innobase/ut/ut0mem.c: Print correct OS error number also on Windows if we run out of memory
Diffstat (limited to 'innobase/ut')
-rw-r--r--innobase/ut/ut0mem.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/innobase/ut/ut0mem.c b/innobase/ut/ut0mem.c
index 03f15031fdf..d36ee2db953 100644
--- a/innobase/ut/ut0mem.c
+++ b/innobase/ut/ut0mem.c
@@ -88,7 +88,13 @@ ut_malloc_low(
"InnoDB: a big enough maximum process size.\n"
"InnoDB: We now intentionally generate a seg fault so that\n"
"InnoDB: on Linux we get a stack trace.\n",
- n, ut_total_allocated_memory, errno);
+ n, ut_total_allocated_memory,
+#ifdef __WIN__
+ (ulint)GetLastError()
+#else
+ (ulint)errno
+#endif
+ );
/* Flush stderr to make more probable that the error
message gets in the error file before we generate a seg