commit | 1dfa77c290cd42e5c9aea5b883ef447f011a3fac | [log] [tgz] |
---|---|---|
author | MITSUNARI Shigeo <herumi@nifty.com> | Wed Apr 17 20:53:47 2013 +0900 |
committer | MITSUNARI Shigeo <herumi@nifty.com> | Wed Apr 17 20:53:47 2013 +0900 |
tree | 24029ee8481e618012fdf37ca103e5dbdb5284d8 | |
parent | 8804abc109a7f4d8e820e50178ade48859279f2b [diff] |
avoid exception in destructor
diff --git a/xbyak/xbyak_util.h b/xbyak/xbyak_util.h index bef4326..7e3bbf4 100644 --- a/xbyak/xbyak_util.h +++ b/xbyak/xbyak_util.h
@@ -356,7 +356,16 @@ } ~StackFrame() { - if (makeEpilog_) close(); + if (!makeEpilog_) return; + try { + close(); + } catch (Xbyak::Error e) { + printf("ERR:StackFrame %s\n", ConvertErrorToString(e)); + exit(1); + } catch (...) { + printf("ERR:StackFrame otherwise\n"); + exit(1); + } } private: const int *getOrderTbl() const