fixed: DbBase::ConvertTime(tm) should not have been used in this way as it was

(it uses a static buffer)
       now DbTextStream can get tm struct so you don't have to use ConvertTime 


git-svn-id: svn://ttmath.org/publicrep/winix/trunk@662 e52654a7-88a9-db11-a3e9-0013d4bc506e
This commit is contained in:
2010-10-09 20:27:45 +00:00
parent 69c634d53f
commit 07511a2eb0
7 changed files with 62 additions and 12 deletions

View File

@@ -44,8 +44,8 @@ void DbItemColumns::SetItem(PGresult * r, long row, Item & item)
if( user_id != -1 ) item.user_id = DbBase::AssertValueLong(r, row, user_id);
if( group_id != -1 ) item.group_id = DbBase::AssertValueLong(r, row, group_id);
if( privileges != -1 ) item.privileges = DbBase::AssertValueInt(r, row, privileges);
if( date_creation != -1 ) item.date_creation = DbBase::ConvertTime( DbBase::AssertValue(r, row, date_creation) );
if( date_modification != -1 ) item.date_modification = DbBase::ConvertTime( DbBase::AssertValue(r, row, date_modification) );
if( date_creation != -1 ) item.date_creation = DbBase::AssertValueTm(r, row, date_creation);
if( date_modification != -1 ) item.date_modification = DbBase::AssertValueTm(r, row, date_modification);
if( url != -1 ) item.url = DbBase::AssertValue(r, row, url);
if( type != -1 ) item.type = static_cast<Item::Type>( DbBase::AssertValueInt(r, row, type) );
if( parent_id != -1 ) item.parent_id = DbBase::AssertValueLong(r, row, parent_id);