diff options
Diffstat (limited to '')
-rw-r--r-- | linden/indra/llmessage/lluseroperation.cpp | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/linden/indra/llmessage/lluseroperation.cpp b/linden/indra/llmessage/lluseroperation.cpp index 29146ea..f43e02a 100644 --- a/linden/indra/llmessage/lluseroperation.cpp +++ b/linden/indra/llmessage/lluseroperation.cpp | |||
@@ -42,7 +42,8 @@ LLUserOperationMgr* gUserOperationMgr = NULL; | |||
42 | 42 | ||
43 | LLUserOperation::LLUserOperation(const LLUUID& agent_id) | 43 | LLUserOperation::LLUserOperation(const LLUUID& agent_id) |
44 | : mAgentID(agent_id), | 44 | : mAgentID(agent_id), |
45 | mTimer() | 45 | mTimer(), |
46 | mNoExpire(FALSE) | ||
46 | { | 47 | { |
47 | mTransactionID.generate(); | 48 | mTransactionID.generate(); |
48 | } | 49 | } |
@@ -51,14 +52,16 @@ LLUserOperation::LLUserOperation(const LLUUID& agent_id, | |||
51 | const LLUUID& transaction_id) : | 52 | const LLUUID& transaction_id) : |
52 | mAgentID(agent_id), | 53 | mAgentID(agent_id), |
53 | mTransactionID(transaction_id), | 54 | mTransactionID(transaction_id), |
54 | mTimer() | 55 | mTimer(), |
56 | mNoExpire(FALSE) | ||
55 | { | 57 | { |
56 | } | 58 | } |
57 | 59 | ||
58 | // protected constructor which is used by base classes that determine | 60 | // protected constructor which is used by base classes that determine |
59 | // transaction, agent, et. after construction. | 61 | // transaction, agent, et. after construction. |
60 | LLUserOperation::LLUserOperation() : | 62 | LLUserOperation::LLUserOperation() : |
61 | mTimer() | 63 | mTimer(), |
64 | mNoExpire(FALSE) | ||
62 | { | 65 | { |
63 | } | 66 | } |
64 | 67 | ||
@@ -66,11 +69,19 @@ LLUserOperation::~LLUserOperation() | |||
66 | { | 69 | { |
67 | } | 70 | } |
68 | 71 | ||
72 | void LLUserOperation::SetNoExpireFlag(const BOOL flag) | ||
73 | { | ||
74 | mNoExpire = flag; | ||
75 | } | ||
69 | 76 | ||
70 | BOOL LLUserOperation::isExpired() | 77 | BOOL LLUserOperation::isExpired() |
71 | { | 78 | { |
72 | const F32 EXPIRE_TIME_SECS = 10.f; | 79 | if (!mNoExpire) |
73 | return mTimer.getElapsedTimeF32() > EXPIRE_TIME_SECS; | 80 | { |
81 | const F32 EXPIRE_TIME_SECS = 10.f; | ||
82 | return mTimer.getElapsedTimeF32() > EXPIRE_TIME_SECS; | ||
83 | } | ||
84 | return FALSE; | ||
74 | } | 85 | } |
75 | 86 | ||
76 | void LLUserOperation::expire() | 87 | void LLUserOperation::expire() |