summaryrefslogtreecommitdiff
path: root/svl/source/svdde/ddecli.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2015-07-07 14:44:59 +0200
committerStephan Bergmann <sbergman@redhat.com>2015-07-07 14:52:35 +0200
commit64fe80db1f06c01084a1c8c498ac874ce4e476ce (patch)
tree8e1f4b47ac465c2c102c4bc8015f7b6e1f5d19f3 /svl/source/svdde/ddecli.cxx
parent2b429eff07ed3e3049e47e0219669a47bada4905 (diff)
Replace GetAppData(SHL_SVDDE) with a static pointer var
Change-Id: I63d35dc3dbfb1185d5795316d2c1d77745d85451
Diffstat (limited to 'svl/source/svdde/ddecli.cxx')
-rw-r--r--svl/source/svdde/ddecli.cxx23
1 files changed, 15 insertions, 8 deletions
diff --git a/svl/source/svdde/ddecli.cxx b/svl/source/svdde/ddecli.cxx
index 860f7c65579b..f771075a333d 100644
--- a/svl/source/svdde/ddecli.cxx
+++ b/svl/source/svdde/ddecli.cxx
@@ -29,20 +29,27 @@
#include <tools/solarmutex.hxx>
#include <osl/mutex.hxx>
-DdeInstData* ImpInitInstData()
+namespace {
+
+DdeInstData * theDdeInstData;
+
+}
+
+DdeInstData* ImpGetInstData()
{
- DdeInstData* pData = new DdeInstData;
+ return theDdeInstData;
+}
- DdeInstData** ppInst = (DdeInstData**)GetAppData( SHL_SVDDE );
- *ppInst = pData;
- return pData;
+DdeInstData* ImpInitInstData()
+{
+ theDdeInstData = new DdeInstData;
+ return theDdeInstData;
}
void ImpDeinitInstData()
{
- DdeInstData** ppInst = (DdeInstData**)GetAppData( SHL_SVDDE );
- delete (*ppInst);
- *ppInst = 0;
+ delete theDdeInstData;
+ theDdeInstData = 0;
}