summaryrefslogtreecommitdiff
path: root/indra/llcommon/llcoros.h
diff options
context:
space:
mode:
authorOz Linden <oz@lindenlab.com>2013-11-19 17:59:55 -0500
committerOz Linden <oz@lindenlab.com>2013-11-19 17:59:55 -0500
commit0031e9a97be1bf6e9fe773c23506494d09ce91ae (patch)
tree220f195c82174b7cc8e94dceb2553e59fe5837a5 /indra/llcommon/llcoros.h
parentb7edc965bc77ab21e9a1e3f6b424299a50053529 (diff)
parentebc9bcbf69f7a519677a6522979a6bf6cbb04bb8 (diff)
merge up to 3.6.10-release; some of the storm-68 changes lost
Diffstat (limited to 'indra/llcommon/llcoros.h')
-rwxr-xr-x[-rw-r--r--]indra/llcommon/llcoros.h12
1 files changed, 8 insertions, 4 deletions
diff --git a/indra/llcommon/llcoros.h b/indra/llcommon/llcoros.h
index d75f28ec1a..01ee11da1a 100644..100755
--- a/indra/llcommon/llcoros.h
+++ b/indra/llcommon/llcoros.h
@@ -29,7 +29,7 @@
#if ! defined(LL_LLCOROS_H)
#define LL_LLCOROS_H
-#include <boost/coroutine/coroutine.hpp>
+#include <boost/dcoroutine/coroutine.hpp>
#include "llsingleton.h"
#include <boost/ptr_container/ptr_map.hpp>
#include <string>
@@ -78,8 +78,8 @@
class LL_COMMON_API LLCoros: public LLSingleton<LLCoros>
{
public:
- /// Canonical boost::coroutines::coroutine signature we use
- typedef boost::coroutines::coroutine<void()> coro;
+ /// Canonical boost::dcoroutines::coroutine signature we use
+ typedef boost::dcoroutines::coroutine<void()> coro;
/// Canonical 'self' type
typedef coro::self self;
@@ -125,7 +125,7 @@ public:
template <typename CALLABLE>
std::string launch(const std::string& prefix, const CALLABLE& callable)
{
- return launchImpl(prefix, new coro(callable));
+ return launchImpl(prefix, new coro(callable, mStackSize));
}
/**
@@ -152,6 +152,9 @@ public:
/// getName() by self.get_id()
std::string getNameByID(const void* self_id) const;
+ /// for delayed initialization
+ void setStackSize(S32 stacksize);
+
private:
friend class LLSingleton<LLCoros>;
LLCoros();
@@ -159,6 +162,7 @@ private:
std::string generateDistinctName(const std::string& prefix) const;
bool cleanup(const LLSD&);
+ S32 mStackSize;
typedef boost::ptr_map<std::string, coro> CoroMap;
CoroMap mCoros;
};