8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-22 17:23:03 +01:00

Roll back implementation of Claudio suggestion for consturctor of BID structure. It forced addition of constructors for message structures generated by GPRE which is not correct

This commit is contained in:
skidder 2004-10-03 20:18:13 +00:00
parent b0a4960f5a
commit 3e6b170862
5 changed files with 12 additions and 14 deletions

View File

@ -25,7 +25,7 @@
//
//____________________________________________________________
//
// $Id: int_cxx.cpp,v 1.37 2004-10-03 04:43:43 robocop Exp $
// $Id: int_cxx.cpp,v 1.38 2004-10-03 20:18:09 skidder Exp $
//
#include "firebird.h"
@ -650,11 +650,7 @@ static void gen_variable( const act* action, int column)
static void make_port( gpre_port* port, int column)
{
// CVC: C++ compliance with constructors.
if (isLangCpp(gpreGlob.sw_language))
printa(column, "struct isc_%d_t {", port->por_ident);
else
printa(column, "struct {");
printa(column, "struct {");
for (REF reference = port->por_references; reference;
reference = reference->ref_next)

View File

@ -33,7 +33,7 @@
*
*/
/*
$Id: blb.cpp,v 1.90 2004-10-01 21:12:46 skidder Exp $
$Id: blb.cpp,v 1.91 2004-10-03 20:18:11 skidder Exp $
*/
#include "firebird.h"
@ -930,7 +930,7 @@ void BLB_move(thread_db* tdbb, dsc* from_desc, dsc* to_desc, jrd_nod* field)
ERR_post(isc_bad_segstr_id, 0);
}
}
source = reinterpret_cast<bid*>(&blobIndex->bli_blob_id);
source = &blobIndex->bli_blob_id;
continue;
}
else {
@ -963,7 +963,7 @@ void BLB_move(thread_db* tdbb, dsc* from_desc, dsc* to_desc, jrd_nod* field)
// If we didn't find materialized blob in transaction blob index it
// means memory structures are inconsistent and crash is appropriate
blobIndex->bli_materialized = true;
blobIndex->bli_blob_id = *reinterpret_cast<ISC_QUAD*>(destination);
blobIndex->bli_blob_id = *destination;
// Assign temporary BLOB ownership to top-level request if it is not assigned yet
jrd_req* own_request;
if (blobIndex->bli_request) {
@ -1010,6 +1010,7 @@ void BLB_move_from_string(thread_db* tdbb, const dsc* from_desc, dsc* to_desc, j
UCHAR *fromstr = 0;
bid temp_bid;
DSC blob_desc;
temp_bid.clear();
MOVE_CLEAR(&blob_desc, sizeof(blob_desc));
blob = BLB_create(tdbb, tdbb->tdbb_request->req_transaction, &temp_bid);
blob_desc.dsc_length = MOV_get_string_ptr(from_desc, &ttype, &fromstr, 0, 0);

View File

@ -62,10 +62,6 @@ struct bid {
} bid_quad;
};
bid() {
clear();
}
ULONG& bid_temp_id() {
// Make sure that compiler packed structure like we wanted
fb_assert(sizeof(*this) == 8);

View File

@ -1852,6 +1852,8 @@ static bool create_relation(thread_db* tdbb,
jrd_req* handle;
Lock* lock;
blob_id.clear();
SET_TDBB(tdbb);
Database* dbb = tdbb->tdbb_database;
const USHORT major_version = dbb->dbb_ods_version;
@ -3211,6 +3213,7 @@ static void get_procedure_dependencies(DeferredWork* work)
jrd_prc* procedure = NULL;
bid blob_id;
blob_id.clear();
jrd_req* handle = CMP_find_request(tdbb, irq_c_prc_dpd, IRQ_REQUESTS);
@ -3284,6 +3287,7 @@ static void get_trigger_dependencies( DeferredWork* work)
jrd_req* handle = CMP_find_request(tdbb, irq_c_trigger, IRQ_REQUESTS);
bid blob_id;
blob_id.clear();
FOR(REQUEST_HANDLE handle)
X IN RDB$TRIGGERS WITH
@ -3526,6 +3530,7 @@ static bool make_version(thread_db* tdbb, SSHORT phase, DeferredWork* work,
TemporaryField* external;
jrd_rel* relation;
bid blob_id;
blob_id.clear();
USHORT n, external_flag = 0;
bool computed_field;

View File

@ -59,7 +59,7 @@ struct BlobIndex {
bool bli_materialized;
jrd_req* bli_request;
union {
ISC_QUAD bli_blob_id; // ID of materialized blob
bid bli_blob_id; // ID of materialized blob
blb* bli_blob_object; // Blob object
};
static const ULONG& generate(const void *sender, const BlobIndex& item) {