summaryrefslogtreecommitdiff
path: root/include/desktop
diff options
context:
space:
mode:
authorGopi Krishna Menon <gopi.menon@collabora.com>2021-06-17 13:23:11 +0000
committerTor Lillqvist <tml@collabora.com>2021-06-18 11:00:57 +0200
commit781c70a8c87878ac0e53c9c4619a4d19d3d737de (patch)
tree242efb62a362e1ad0ecb3740d86b2301bc0e3b80 /include/desktop
parent3c24e7ed972ae2fc431365e4884e27c0b243c905 (diff)
Add Last 4 UNO Commands To CrashReport Dump
Adds last 4 uno commands executed in CrashReport to assist in investigating the crashes Change-Id: Ib7307ffc62d6d51d52f9d5e7fabefc2eaf858e5b Reviewed-on: https://gerrit.libreoffice.org/c/core/+/117388 Tested-by: Jenkins Reviewed-by: Tor Lillqvist <tml@collabora.com>
Diffstat (limited to 'include/desktop')
-rw-r--r--include/desktop/crashreport.hxx12
1 files changed, 12 insertions, 0 deletions
diff --git a/include/desktop/crashreport.hxx b/include/desktop/crashreport.hxx
index e7fd0d15d39b..403e3117117d 100644
--- a/include/desktop/crashreport.hxx
+++ b/include/desktop/crashreport.hxx
@@ -20,6 +20,7 @@
// vector not sort the entries
#include <memory>
#include <vector>
+#include <deque>
#include <string>
namespace google_breakpad
@@ -53,6 +54,9 @@ public:
static void setActiveSfxObjectName(const OUString& rActiveSfxObjectName);
static OUString getActiveSfxObjectName();
+ static void logUnoCommand(const OUString& rUnoCommand);
+ static OUString getLoggedUnoCommands();
+
static bool crashReportInfoExists();
static bool readSendConfig(std::string& response);
@@ -62,6 +66,7 @@ public:
private:
static osl::Mutex maMutex;
static osl::Mutex maActiveSfxObjectNameMutex;
+ static osl::Mutex maUnoLogCmdMutex;
static bool mbInit;
typedef struct _mpair
{
@@ -76,6 +81,8 @@ private:
typedef std::vector<mpair> vmaKeyValues;
static vmaKeyValues maKeyValues; // used to temporarily save entries before the old info has been uploaded
+ typedef std::deque<OUString> vmaloggedUnoCommands;
+ static vmaloggedUnoCommands maloggedUnoCommands;
static OUString msActiveSfxObjectName;
static std::unique_ptr<google_breakpad::ExceptionHandler> mpExceptionHandler;
@@ -98,6 +105,11 @@ private:
{
return OUString();
}
+ inline static void logUnoCommand(SAL_UNUSED_PARAMETER const OUString& /*rUnoCommand*/) {};
+ inline static OUString getLoggedUnoCommands()
+ {
+ return OUString();
+ }
#endif // HAVE_FEATURE_BREAKPAD
};