8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-23 22:03:03 +01:00
This commit is contained in:
asfernandes 2009-12-23 21:43:37 +00:00
parent a8a37263a1
commit 2d62037b2a
4 changed files with 19 additions and 20 deletions

View File

@ -857,12 +857,12 @@ static FETCH_CODE fetch_page(thread_db* tdbb,
// sometimes will fetch the same page more than once. In that
// event we don't report double allocation. If the page is truely
// double allocated (to more than one relation) we'll find it
// when the on-page relation id doesn't match
// when the on-page relation id doesn't match.
// We also don't test SCN's pages here. If it double allocated this
// will be detected when wrong page reference will be fetched with
// non pag_scns type.
if ((type != pag_data) && (type != pag_scns) &&
if (type != pag_data && type != pag_scns &&
PageBitmap::test(control->vdr_page_bitmap, page_number))
{
corrupt(tdbb, control, VAL_PAG_DOUBLE_ALLOC, 0, page_number);
@ -1589,7 +1589,7 @@ static RTN walk_index(thread_db* tdbb, vdr* control, jrd_rel* relation,
nullKeyNode = false;
}
if ((node.recordNumber.getValue() >= 0) && !firstNode && !node.isEndLevel)
if (node.recordNumber.getValue() >= 0 && !firstNode && !node.isEndLevel)
{
// If this node is equal to the previous one and it's
// not a MARKER, record number should be same or higher.

View File

@ -1061,4 +1061,3 @@ COMMIT WORK;
stop
COMMIT WORK;

View File

@ -849,6 +849,7 @@ void usage(bool listSwitches)
{
printf("%s\n", getMessage(i).c_str());
}
if (! listSwitches)
{
printf("%s\n", getMessage(53).c_str());

View File

@ -738,7 +738,6 @@ void NBackup::unlock_database()
void NBackup::backup_database(int level, const PathName& fname)
{
bool database_locked = false;
// We set this flag when backup file is in inconsistent state
bool delete_backup = false;
@ -841,8 +840,8 @@ void NBackup::backup_database(int level, const PathName& fname)
// Read database header
char unaligned_header_buffer[SECTOR_ALIGNMENT * 2];
Ods::header_page *header =
reinterpret_cast<Ods::header_page*>(FB_ALIGN((IPTR) unaligned_header_buffer, SECTOR_ALIGNMENT));
Ods::header_page *header = reinterpret_cast<Ods::header_page*>(
FB_ALIGN((IPTR) unaligned_header_buffer, SECTOR_ALIGNMENT));
if (read_file(dbase, header, SECTOR_ALIGNMENT/*sizeof(*header)*/) != SECTOR_ALIGNMENT/*sizeof(*header)*/)
status_exception::raise(Arg::Gds(isc_nbackup_err_eofhdrdb) << dbname.c_str() << Arg::Num(1));
@ -1587,7 +1586,7 @@ void nbackup(UtilSvc* uSvc)
}
catch (const Exception& e)
{
if ((!uSvc->isService()) && (!nbk.printed()))
if (!uSvc->isService() && !nbk.printed())
{
ISC_STATUS_ARRAY status;
e.stuff_exception(status);