dtmail: remove DEAD_WOOD code
This commit is contained in:
@@ -548,26 +548,6 @@ DtMailEnv::vSetError(const DTMailError_t minor_code,
|
||||
delete [] messageBuffer;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
const char *
|
||||
DtMailEnv::implGetMessage()
|
||||
{
|
||||
if (_client != NULL && _implMessageFunc != NULL) {
|
||||
return((*_implMessageFunc)(_client));
|
||||
}
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
int
|
||||
DtMailEnv::implGetError()
|
||||
{
|
||||
if (_client != NULL && _implErrorFunc != NULL) {
|
||||
return((*_implErrorFunc)(_client));
|
||||
}
|
||||
return(0);
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
void
|
||||
DtMailEnv::logError(DtMailBoolean criticalError, const char *format, ...) const
|
||||
{
|
||||
@@ -598,17 +578,3 @@ DtMailEnv::logError(DtMailBoolean criticalError, const char *format, ...) const
|
||||
NULL, messageBuffer);
|
||||
delete [] messageBuffer;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMailEnv::logFatalError(DtMailBoolean criticalError, const char *format, ...)
|
||||
{
|
||||
_fatal = DTM_TRUE;
|
||||
|
||||
va_list var_args;
|
||||
|
||||
va_start(var_args, format);
|
||||
logError(criticalError, format, var_args);
|
||||
va_end(var_args);
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
@@ -111,41 +111,12 @@ DtMailValue::toDate(void)
|
||||
return(date);
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMailValue::fromDate(const DtMailValueDate & date)
|
||||
{
|
||||
if (_value) {
|
||||
free(_value);
|
||||
}
|
||||
|
||||
_value = (char *)malloc(64);
|
||||
|
||||
tm result;
|
||||
|
||||
SafeLocaltime(&date.dtm_date, result);
|
||||
|
||||
/* NL_COMMENT
|
||||
* The %C is the time and date format, please refer to strftime man page for
|
||||
* explanation of each format.
|
||||
*/
|
||||
SafeStrftime(_value, 64, DtMailError::getMessageText(2, 1, "%C"), &result);
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
DtMailAddressSeq *
|
||||
DtMailValue::toAddress(void)
|
||||
{
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMailValue::fromAddress(const DtMailAddressSeq &)
|
||||
{
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
const char *
|
||||
DtMailValue::raw(void)
|
||||
{
|
||||
|
||||
@@ -457,14 +457,6 @@ FileShare::readWriteOverride(DtMailEnv & error)
|
||||
return(answer);
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
DtMailBoolean
|
||||
FileShare::locked(void)
|
||||
{
|
||||
return(_have_write_access);
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
Tt_message
|
||||
FileShare::fileCB(Tt_message msg,
|
||||
Tttk_op op,
|
||||
|
||||
@@ -61,57 +61,6 @@ ObjectKey::~ObjectKey(void)
|
||||
delete _type;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
int
|
||||
ObjectKey::operator==(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator== called");
|
||||
return(0);
|
||||
}
|
||||
|
||||
int
|
||||
ObjectKey::operator!=(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator!= called\n");
|
||||
return(0);
|
||||
}
|
||||
|
||||
int
|
||||
ObjectKey::operator<(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator< called\n");
|
||||
return(0);
|
||||
}
|
||||
|
||||
int
|
||||
ObjectKey::operator<=(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator<= called\n");
|
||||
return(0);
|
||||
}
|
||||
|
||||
int
|
||||
ObjectKey::operator>(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator> called\n");
|
||||
return(0);
|
||||
}
|
||||
|
||||
int
|
||||
ObjectKey::operator>=(ObjectKey &)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::operator>= called\n");
|
||||
return(0);
|
||||
}
|
||||
|
||||
HashVal
|
||||
ObjectKey::hashValue(void)
|
||||
{
|
||||
assert(!"Pure virtual ObjectKey::hashValue called\n");
|
||||
return(0);
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
HashVal
|
||||
ObjectKey::genericHashValue(void * buf, int len)
|
||||
{
|
||||
|
||||
@@ -851,15 +851,6 @@ DtMail::Session::registerDisableGroupPrivilegesCallback(
|
||||
_disableGroupPrivileges_cb_data = cb_data;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMail::Session::unregisterDisableGroupPrivilegesCallback(void)
|
||||
{
|
||||
_disableGroupPrivileges_cb = NULL;
|
||||
_disableGroupPrivileges_cb_data = NULL;
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
void
|
||||
DtMail::Session::disableGroupPrivileges(void)
|
||||
{
|
||||
@@ -877,15 +868,6 @@ DtMail::Session::registerEnableGroupPrivilegesCallback(
|
||||
_enableGroupPrivileges_cb_data = cb_data;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMail::Session::unregisterEnableGroupPrivilegesCallback(void)
|
||||
{
|
||||
_enableGroupPrivileges_cb = NULL;
|
||||
_enableGroupPrivileges_cb_data = NULL;
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
void
|
||||
DtMail::Session::enableGroupPrivileges(void)
|
||||
{
|
||||
@@ -903,15 +885,6 @@ DtMail::Session::registerBusyCallback(DtMailEnv&,
|
||||
_busy_cb_data = cb_data;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
DtMail::Session::unregisterBusyCallback(DtMailEnv & error)
|
||||
{
|
||||
_busy_cb = NULL;
|
||||
_busy_cb_data = NULL;
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
void
|
||||
DtMail::Session::setBusyState(DtMailEnv &error, DtMailBusyState busy_state)
|
||||
{
|
||||
|
||||
@@ -368,91 +368,6 @@ Condition::waitTrue(void)
|
||||
return;
|
||||
}
|
||||
|
||||
#ifdef DEAD_WOOD
|
||||
void
|
||||
Condition::waitFalse(void)
|
||||
{
|
||||
// Wait for the condition to become true.
|
||||
//
|
||||
#if defined(POSIX_THREADS)
|
||||
MutexLock lock_scope(_mutex);
|
||||
|
||||
while(_state) {
|
||||
cond_wait((cond_t *)_condition, (mutex_t *)_mutex);
|
||||
}
|
||||
#else
|
||||
_state = 0;
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void
|
||||
Condition::waitFor(int new_state)
|
||||
{
|
||||
// Wait for the condition to become true.
|
||||
//
|
||||
#if defined(POSIX_THREADS)
|
||||
MutexLock lock_scope(_mutex);
|
||||
|
||||
while(_state != new_state) {
|
||||
cond_wait((cond_t *)_condition, (mutex_t *)_mutex);
|
||||
}
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void
|
||||
Condition::waitGT(int new_state)
|
||||
{
|
||||
// Wait for the condition to become true.
|
||||
//
|
||||
#if defined(POSIX_THREADS)
|
||||
MutexLock lock_scope(_mutex);
|
||||
|
||||
while(_state > new_state) {
|
||||
cond_wait((cond_t *)_condition, (mutex_t *)_mutex);
|
||||
}
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void
|
||||
Condition::waitLT(int new_state)
|
||||
{
|
||||
// Wait for the condition to become true.
|
||||
//
|
||||
#if defined(POSIX_THREADS)
|
||||
MutexLock lock_scope(_mutex);
|
||||
|
||||
while(_state < new_state) {
|
||||
cond_wait((cond_t *)_condition, (mutex_t *)_mutex);
|
||||
}
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
void
|
||||
Condition::waitProcStatus(void)
|
||||
{
|
||||
// Wait for the condition to become true.
|
||||
//
|
||||
#if defined(POSIX_THREADS)
|
||||
MutexLock lock_scope(_mutex);
|
||||
|
||||
while(_state < 0) {
|
||||
cond_wait((cond_t *)_condition, (mutex_t *)_mutex);
|
||||
}
|
||||
#else
|
||||
_state = 0;
|
||||
#endif
|
||||
|
||||
return;
|
||||
}
|
||||
#endif /* DEAD_WOOD */
|
||||
|
||||
Thread
|
||||
ThreadCreate(
|
||||
|
||||
Reference in New Issue
Block a user