From 330f78f3334bcdcdb4cc2ab2dbf66604e0224d71 Mon Sep 17 00:00:00 2001
From: lichao <lichao@aiotlink.com>
Date: 星期五, 21 五月 2021 16:21:45 +0800
Subject: [PATCH] Merge branch 'master' of http://192.168.5.5:10010/r/valib/bhshmq
---
src/bh_util.h | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/bh_util.h b/src/bh_util.h
index 223da2a..15ffeb0 100644
--- a/src/bh_util.h
+++ b/src/bh_util.h
@@ -157,9 +157,9 @@
}
protected:
- static inline T &GetData()
+ static inline T &GetData(const std::string &msg = "Must set data before use!")
{
- if (!ptr()) { throw std::string("Must set ShmMsg shm before use!"); }
+ if (!ptr()) { throw std::logic_error(msg); }
return *ptr();
}
--
Gitblit v1.8.0