summaryrefslogtreecommitdiff
path: root/indra/llcommon
diff options
context:
space:
mode:
authorSteven Bennetts <steve@lindenlab.com>2008-03-15 01:18:27 +0000
committerSteven Bennetts <steve@lindenlab.com>2008-03-15 01:18:27 +0000
commit672a76d0ea08a0d0fc824e103ee4c4242b7e03ec (patch)
treeb623a9c884383ad75ed755b2c373db2b90643671 /indra/llcommon
parent04611efae8a3291ceba8a29dd920bdae0d404830 (diff)
reverting premature commit at 82410.
Diffstat (limited to 'indra/llcommon')
-rw-r--r--indra/llcommon/indra_constants.h2
-rw-r--r--indra/llcommon/llevent.h7
-rw-r--r--indra/llcommon/llfile.cpp11
3 files changed, 12 insertions, 8 deletions
diff --git a/indra/llcommon/indra_constants.h b/indra/llcommon/indra_constants.h
index 89b276e3b3..a0fb086029 100644
--- a/indra/llcommon/indra_constants.h
+++ b/indra/llcommon/indra_constants.h
@@ -339,7 +339,7 @@ const U32 MAP_ITEM_LAND_FOR_SALE = 0x07;
const U32 MAP_ITEM_CLASSIFIED = 0x08;
// Crash reporter behavior
-const char* const CRASH_SETTINGS_FILE = "settings_crash_behavior.xml";
+const char* const CRASH_SETTINGS_FILE = "crash_settings.xml";
const char* const CRASH_BEHAVIOR_SETTING = "CrashSubmitBehavior";
const S32 CRASH_BEHAVIOR_ASK = 0;
const S32 CRASH_BEHAVIOR_ALWAYS_SEND = 1;
diff --git a/indra/llcommon/llevent.h b/indra/llcommon/llevent.h
index 741b40b787..8ba883a0ee 100644
--- a/indra/llcommon/llevent.h
+++ b/indra/llcommon/llevent.h
@@ -185,6 +185,13 @@ protected:
LLPointer<LLEventDispatcher> mDispatcher;
};
+// Utility mixer class which fires & handles events
+class LLSimpleListenerObservable : public LLObservable, public LLSimpleListener
+{
+public:
+ virtual bool handleEvent(LLPointer<LLEvent> event, const LLSD& userdata) = 0;
+};
+
class LLValueChangedEvent : public LLEvent
{
public:
diff --git a/indra/llcommon/llfile.cpp b/indra/llcommon/llfile.cpp
index c44650009d..2a18e5c64c 100644
--- a/indra/llcommon/llfile.cpp
+++ b/indra/llcommon/llfile.cpp
@@ -271,11 +271,9 @@ void llofstream::open(const char* _Filename, /* Flawfinder: ignore */
void llofstream::close()
{ // close the C stream
- if(is_open())
- {
- if (_Filebuffer->close() == 0)
- _Myios::setstate(ios_base::failbit); /*Flawfinder: ignore*/
- }
+ llassert(_Filebuffer);
+ if (_Filebuffer->close() == 0)
+ _Myios::setstate(ios_base::failbit); /*Flawfinder: ignore*/
}
llofstream::llofstream(const char *_Filename,
@@ -287,8 +285,7 @@ llofstream::llofstream(const char *_Filename,
}
llofstream::~llofstream()
-{
- // destroy the object
+{ // destroy the object
close();
delete _Filebuffer;
}