double prevVal = 99999.0;
long ret = pVRepository->ReadSetting( "3DFxAccuracy",&prevVal );
// check preval here, 如果这了读不出来,那么下面的Write也就考虑一下了
if ( -1 == ret ) {
break;
}
ret = pVRepository->WriteSetting( "3DFxAccuracy",&f );
if ( -1 == ret ) {
break;
}
ret = pVRepository->SaveRepository();
if ( 0 != ret ) {
// SaveRepository会替你Commit,这里实际上不需要,只是为了确认一下
ret = pVRepository->Commit();
if ( -1 != ret ) {
// 问题不在commit
break;
}
};