Commit 38429c43 authored by Claes Sjofors's avatar Claes Sjofors

Confict merge and some test messages removed

parent 44529d95
...@@ -1456,7 +1456,6 @@ link_disconnect ( ...@@ -1456,7 +1456,6 @@ link_disconnect (
/* Empty window list */ /* Empty window list */
thread_MutexLock(&lp->eseg_mutex);
for ( for (
sp = lst_Succ(NULL, &lp->lh_win, NULL); sp = lst_Succ(NULL, &lp->lh_win, NULL);
sp != NULL; sp != NULL;
......
...@@ -65,7 +65,7 @@ wb_db_info::wb_db_info(wb_db *db) : ...@@ -65,7 +65,7 @@ wb_db_info::wb_db_info(wb_db *db) :
void wb_db_info::get(wb_db_txn *txn) void wb_db_info::get(wb_db_txn *txn)
{ {
int index = 1; int index = 1;
int ret; int ret = 0;
Dbt key(&index, sizeof(index)); Dbt key(&index, sizeof(index));
Dbt data(&m_volume, sizeof(m_volume)); Dbt data(&m_volume, sizeof(m_volume));
data.set_ulen(sizeof(m_volume)); data.set_ulen(sizeof(m_volume));
...@@ -73,7 +73,7 @@ void wb_db_info::get(wb_db_txn *txn) ...@@ -73,7 +73,7 @@ void wb_db_info::get(wb_db_txn *txn)
try { try {
ret = m_db->m_t_info->get(txn, &key, &data, 0); ret = m_db->m_t_info->get(txn, &key, &data, 0);
printf("info get: %d\n", ret); // printf("info get: %d\n", ret);
} catch (DbException &e) { } catch (DbException &e) {
printf("info get Error, %d\n", ret); printf("info get Error, %d\n", ret);
m_db->m_t_info->err(ret, "m_db->m_t_info->get(txn, &key, &data, 0)"); m_db->m_t_info->err(ret, "m_db->m_t_info->get(txn, &key, &data, 0)");
...@@ -90,7 +90,7 @@ void wb_db_info::put(wb_db_txn *txn) ...@@ -90,7 +90,7 @@ void wb_db_info::put(wb_db_txn *txn)
m_key.set_size(sizeof(index)); m_key.set_size(sizeof(index));
ret = m_db->m_t_info->put(txn, &m_key, &m_data, 0); ret = m_db->m_t_info->put(txn, &m_key, &m_data, 0);
printf("info put: %d\n", ret); // printf("info put: %d\n", ret);
} }
wb_db_class::wb_db_class(wb_db *db) : wb_db_class::wb_db_class(wb_db *db) :
...@@ -822,6 +822,8 @@ wb_db::wb_db(pwr_tVid vid) : ...@@ -822,6 +822,8 @@ wb_db::wb_db(pwr_tVid vid) :
void wb_db::close() void wb_db::close()
{ {
int rc;
m_t_ohead->close(0); m_t_ohead->close(0);
m_t_rbody->close(0); m_t_rbody->close(0);
m_t_dbody->close(0); m_t_dbody->close(0);
...@@ -831,8 +833,8 @@ void wb_db::close() ...@@ -831,8 +833,8 @@ void wb_db::close()
if (m_txn) { if (m_txn) {
printstat(m_env, "before abort"); printstat(m_env, "before abort");
int rc = m_txn->abort(); rc = m_txn->abort();
printf("int rc = m_txn->abort(): %d\n", rc); // printf("int rc = m_txn->abort(): %d\n", rc);
} }
printstat(m_env, "before m_env->close(0)"); printstat(m_env, "before m_env->close(0)");
...@@ -1075,7 +1077,7 @@ void wb_db::openDb(bool useTxn) ...@@ -1075,7 +1077,7 @@ void wb_db::openDb(bool useTxn)
get_config( m_fileName, &lk_max_locks, &lk_max_objects, &log_autoremove); get_config( m_fileName, &lk_max_locks, &lk_max_objects, &log_autoremove);
m_env = new DbEnv(0/*DB_CXX_NO_EXCEPTIONS*/); m_env = new DbEnv(0/*DB_CXX_NO_EXCEPTIONS*/);
printf("%s\n", m_env->version(0, 0, 0)); // printf("%s\n", m_env->version(0, 0, 0));
m_env->set_errpfx("PWR db"); m_env->set_errpfx("PWR db");
m_env->set_cachesize(0, 256 * 1024 * 1024, 0); m_env->set_cachesize(0, 256 * 1024 * 1024, 0);
rc = m_env->set_lg_bsize(1024*1024*2); rc = m_env->set_lg_bsize(1024*1024*2);
......
...@@ -840,7 +840,6 @@ pwr_tStatus Ev::mh_alarmstatus_bc( mh_sAlarmStatus *MsgP) ...@@ -840,7 +840,6 @@ pwr_tStatus Ev::mh_alarmstatus_bc( mh_sAlarmStatus *MsgP)
case evlist_eItemType_Alarm: case evlist_eItemType_Alarm:
if ( MsgP->Nix == item->eventid.Nix && !item->check) { if ( MsgP->Nix == item->eventid.Nix && !item->check) {
ev->ala->event_delete( &item->eventid); ev->ala->event_delete( &item->eventid);
printf( "Sts ala del %d,%d\n", item->eventid.Nix, item->eventid.Idx);
for ( int k = 0; k < ev->sala_cnt; k++) for ( int k = 0; k < ev->sala_cnt; k++)
ev->sala[k]->event_delete( &item->eventid); ev->sala[k]->event_delete( &item->eventid);
i--; i--;
......
...@@ -1960,16 +1960,11 @@ ItemAlarm::ItemAlarm( EvList *item_evlist, const char *item_name, pwr_tTime item ...@@ -1960,16 +1960,11 @@ ItemAlarm::ItemAlarm( EvList *item_evlist, const char *item_name, pwr_tTime item
brow_GetUserData( last_node, (void **)&item); brow_GetUserData( last_node, (void **)&item);
brow_tNode tree_node = item->tree_node; brow_tNode item_tree_node = item->tree_node;
evlist_eItemType item_type = item->type; evlist_eItemType item_type = item->type;
brow_DeleteNode( evlist->browbase->ctx, last_node); brow_DeleteNode( evlist->browbase->ctx, last_node);
if ( item_type == evlist_eItemType_Alarm && item_evlist->browtree) {
if ( tree_node)
brow_DeleteNode( item_evlist->browtree->ctx, tree_node);
item_evlist->view_configure();
}
// Note! This ItemAlarm might be deleted by now if node == last_node // Note! This ItemAlarm might be deleted by now if node == last_node
if ( item_type == evlist_eItemType_Alarm && item_evlist->browtree) { if ( item_type == evlist_eItemType_Alarm && item_evlist->browtree) {
if ( item_tree_node) if ( item_tree_node)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment