diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2012-12-06 09:06:55 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2012-12-06 09:25:42 +0100 |
commit | 7b0df11e4fd3c3de771050a3e4be904b21a3b565 (patch) | |
tree | 79fb39db65d3b5534d2ca0ace02f8c82c462bfc7 /sal | |
parent | 9ead8b3f965ce32beea12961ca2ce418ffbccd5f (diff) |
Put stubs for removed functionality into compat.cxx
Change-Id: I634c6c699f8573113cdf0763c2cc83dcc04b0b0e
(cherry picked from commit c4a8ba908cca0228336330ae72e5d7ad29a6ed2e)
Diffstat (limited to 'sal')
-rw-r--r-- | sal/Library_sal.mk | 2 | ||||
-rw-r--r-- | sal/osl/all/compat.cxx (renamed from sal/osl/all/semaphor.c) | 39 |
2 files changed, 20 insertions, 21 deletions
diff --git a/sal/Library_sal.mk b/sal/Library_sal.mk index 51823fe7bee3..d4fae981585e 100644 --- a/sal/Library_sal.mk +++ b/sal/Library_sal.mk @@ -97,6 +97,7 @@ $(eval $(call gb_Library_use_system_darwin_frameworks,sal,\ endif $(eval $(call gb_Library_add_exception_objects,sal,\ + sal/osl/all/compat \ sal/osl/all/debugbase \ sal/osl/all/loadmodulerelative \ sal/osl/all/log \ @@ -138,7 +139,6 @@ $(eval $(call gb_Library_add_exception_objects,sal,\ )) $(eval $(call gb_Library_add_cobjects,sal,\ sal/osl/all/filepath \ - sal/osl/all/semaphor \ )) ifeq ($(OS),IOS) diff --git a/sal/osl/all/semaphor.c b/sal/osl/all/compat.cxx index 5afb950ad280..fb8a1ec6e2d2 100644 --- a/sal/osl/all/semaphor.c +++ b/sal/osl/all/compat.cxx @@ -7,37 +7,36 @@ * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ -#include <sal/types.h> +#include "sal/config.h" + +#include <cstdlib> + +#include "sal/types.h" // Stubs for removed functionality, to be killed when we bump sal SONAME -SAL_DLLPUBLIC_EXPORT void* SAL_CALL osl_createSemaphore(sal_uInt32 dummy) -{ - (void)dummy; - return NULL; +extern "C" { + +SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_acquireSemaphore(void *) { + for (;;) { std::abort(); } // avoid "must return a value" warnings +} + +SAL_DLLPUBLIC_EXPORT void * SAL_CALL osl_createSemaphore(sal_uInt32) { + for (;;) { std::abort(); } // avoid "must return a value" warnings } -SAL_DLLPUBLIC_EXPORT void SAL_CALL osl_destroySemaphore(void* dummy) -{ - (void)dummy; +SAL_DLLPUBLIC_EXPORT void SAL_CALL osl_destroySemaphore(void *) { + std::abort(); } -SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_acquireSemaphore(void* dummy) -{ - (void)dummy; - return sal_False; +SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_releaseSemaphore(void *) { + for (;;) { std::abort(); } // avoid "must return a value" warnings } -SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_tryToAcquireSemaphore(void* dummy) -{ - (void)dummy; - return sal_False; +SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_tryToAcquireSemaphore(void *) { + for (;;) { std::abort(); } // avoid "must return a value" warnings } -SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL osl_releaseSemaphore(void* dummy) -{ - (void)dummy; - return sal_False; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |