diff --git a/src/dsql/PackageNodes.epp b/src/dsql/PackageNodes.epp index 0e1b57220e..f5a65b9c08 100644 --- a/src/dsql/PackageNodes.epp +++ b/src/dsql/PackageNodes.epp @@ -216,7 +216,7 @@ namespace SortedObjectsArray& functions, SortedObjectsArray& procedures, bool details) { - Database* dbb = tdbb->getDatabase(); + //Database* dbb = tdbb->getDatabase(); AutoCacheRequest requestHandle(tdbb, drq_l_pkg_funcs, DYN_REQUESTS); AutoCacheRequest requestHandle2(tdbb, drq_l_pkg_func_args, DYN_REQUESTS); @@ -478,7 +478,7 @@ void CreateAlterPackageNode::execute(thread_db* tdbb, jrd_tra* transaction) void CreateAlterPackageNode::executeCreate(thread_db* tdbb, jrd_tra* transaction) { Attachment* attachment = tdbb->getAttachment(); - Database* dbb = tdbb->getDatabase(); + //Database* dbb = tdbb->getDatabase(); const MetaName metaName(nameInMetaCharSet(tdbb, name)); executeDdlTrigger(tdbb, transaction, DTW_BEFORE, DDL_TRIGGER_CREATE_PACKAGE, metaName); @@ -527,7 +527,7 @@ void CreateAlterPackageNode::executeCreate(thread_db* tdbb, jrd_tra* transaction bool CreateAlterPackageNode::executeAlter(thread_db* tdbb, jrd_tra* transaction) { - Database* dbb = tdbb->getDatabase(); + //Database* dbb = tdbb->getDatabase(); const MetaName metaName(nameInMetaCharSet(tdbb, name)); AutoCacheRequest requestHandle(tdbb, drq_m_pkg, DYN_REQUESTS); diff --git a/src/dsql/StmtNodes.cpp b/src/dsql/StmtNodes.cpp index d94ab9e262..7b71cacfeb 100644 --- a/src/dsql/StmtNodes.cpp +++ b/src/dsql/StmtNodes.cpp @@ -75,7 +75,7 @@ DmlNode* DmlNode::pass2(thread_db* tdbb, CompilerScratch* csb, jrd_nod* aNode) static RegisterNode regIfNode(blr_if); -DmlNode* IfNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, UCHAR blrOp) +DmlNode* IfNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, UCHAR /*blrOp*/) { IfNode* node = FB_NEW(pool) IfNode(pool); @@ -172,7 +172,7 @@ static RegisterNode regInAutonomousTransactionNode( DmlNode* InAutonomousTransactionNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, - UCHAR blrOp) + UCHAR /*blrOp*/) { InAutonomousTransactionNode* node = FB_NEW(pool) InAutonomousTransactionNode(pool); @@ -746,7 +746,7 @@ jrd_nod* PostEventNode::execute(thread_db* tdbb, jrd_req* request) static RegisterNode regSavepointNode(blr_user_savepoint); -DmlNode* SavepointNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, UCHAR blrOp) +DmlNode* SavepointNode::parse(thread_db* /*tdbb*/, MemoryPool& pool, CompilerScratch* csb, UCHAR /*blrOp*/) { SavepointNode* node = FB_NEW(pool) SavepointNode(pool); @@ -812,13 +812,13 @@ void SavepointNode::genBlr() } -SavepointNode* SavepointNode::pass1(thread_db* tdbb, CompilerScratch* csb) +SavepointNode* SavepointNode::pass1(thread_db* /*tdbb*/, CompilerScratch* /*csb*/) { return this; } -SavepointNode* SavepointNode::pass2(thread_db* tdbb, CompilerScratch* csb) +SavepointNode* SavepointNode::pass2(thread_db* /*tdbb*/, CompilerScratch* /*csb*/) { return this; } @@ -937,7 +937,7 @@ jrd_nod* SavepointNode::execute(thread_db* tdbb, jrd_req* request) static RegisterNode regSuspendNode(blr_send); -DmlNode* SuspendNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, UCHAR blrOp) +DmlNode* SuspendNode::parse(thread_db* tdbb, MemoryPool& pool, CompilerScratch* csb, UCHAR /*blrOp*/) { SuspendNode* node = FB_NEW(pool) SuspendNode(pool); @@ -1001,7 +1001,7 @@ SuspendNode* SuspendNode::pass2(thread_db* tdbb, CompilerScratch* csb) // Execute a SEND statement. -jrd_nod* SuspendNode::execute(thread_db* tdbb, jrd_req* request) +jrd_nod* SuspendNode::execute(thread_db* /*tdbb*/, jrd_req* request) { switch (request->req_operation) { diff --git a/src/dsql/gen.cpp b/src/dsql/gen.cpp index 2d3648b4ae..3f788f452e 100644 --- a/src/dsql/gen.cpp +++ b/src/dsql/gen.cpp @@ -670,7 +670,7 @@ void GEN_expr(CompiledStatement* statement, dsql_nod* node) void GEN_port(CompiledStatement* statement, dsql_msg* message) { thread_db* tdbb = JRD_get_thread_data(); - Jrd::Attachment* att = tdbb->getAttachment(); + //Jrd::Attachment* att = tdbb->getAttachment(); // if (statement->req_blr_string) { stuff(statement, blr_message); diff --git a/src/jrd/AggregateRsb.cpp b/src/jrd/AggregateRsb.cpp index 7d4171cae3..f7ec544a8a 100644 --- a/src/jrd/AggregateRsb.cpp +++ b/src/jrd/AggregateRsb.cpp @@ -131,8 +131,8 @@ bool AggregateRsb::get(thread_db* tdbb, jrd_req* request) if ((impure->irsb_count = evlGroup(tdbb, request, impure->irsb_count))) return true; - else - return false; + + return false; } @@ -145,7 +145,7 @@ void AggregateRsb::markRecursive() // Compute the next aggregated record of a value group. evlGroup is driven by, and returns, a state // variable. The values of the state are: // -// 3 Entering EVL group beforing fetching the first record. +// 3 Entering EVL group before fetching the first record. // 1 Values are pending from a prior fetch // 2 We encountered EOF from the last attempted fetch // 0 We processed everything now process (EOF) @@ -159,8 +159,8 @@ USHORT AggregateRsb::evlGroup(thread_db* tdbb, jrd_req* request, USHORT state) impure_value vtemp; vtemp.vlu_string = NULL; - jrd_nod* map = aggNode->nod_arg[e_agg_map]; - jrd_nod* group = aggNode->nod_arg[e_agg_group]; + jrd_nod* const map = aggNode->nod_arg[e_agg_map]; + jrd_nod* const group = aggNode->nod_arg[e_agg_group]; jrd_nod** ptr; const jrd_nod* const* end; diff --git a/src/jrd/VirtualTable.cpp b/src/jrd/VirtualTable.cpp index 2daf44674f..2b0532d08c 100644 --- a/src/jrd/VirtualTable.cpp +++ b/src/jrd/VirtualTable.cpp @@ -116,13 +116,13 @@ void VirtualTable::erase(thread_db* tdbb, record_param* rpb) } -void VirtualTable::modify(thread_db* tdbb, record_param* /*org_rpb*/, record_param* /*new_rpb*/) +void VirtualTable::modify(thread_db* /*tdbb*/, record_param* /*org_rpb*/, record_param* /*new_rpb*/) { ERR_post(Arg::Gds(isc_read_only)); } -void VirtualTable::store(thread_db* tdbb, record_param* /*rpb*/) +void VirtualTable::store(thread_db* /*tdbb*/, record_param* /*rpb*/) { ERR_post(Arg::Gds(isc_read_only)); } diff --git a/src/jrd/VirtualTable.h b/src/jrd/VirtualTable.h index c34b86d41b..28dcf0d0bb 100644 --- a/src/jrd/VirtualTable.h +++ b/src/jrd/VirtualTable.h @@ -30,7 +30,7 @@ namespace Jrd { class RecordStream //// TODO: create RecordStream.h { public: - RecordStream(RecordSource* aRsb) + explicit RecordStream(RecordSource* aRsb) : rsb(aRsb) { } @@ -40,12 +40,12 @@ public: } public: - virtual void findRsbs(StreamStack* streamList, RsbStack* rsbList) + virtual void findRsbs(StreamStack* streamList, RsbStack* /*rsbList*/) { streamList->push(rsb->rsb_stream); } - virtual void invalidate(thread_db* tdbb, record_param* rpb) + virtual void invalidate(thread_db* /*tdbb*/, record_param* rpb) { rpb->rpb_number.setValid(false); } diff --git a/src/jrd/WindowRsb.cpp b/src/jrd/WindowRsb.cpp index fa1dbd4d73..56ffd0497f 100644 --- a/src/jrd/WindowRsb.cpp +++ b/src/jrd/WindowRsb.cpp @@ -67,7 +67,7 @@ unsigned WindowRsb::dump(UCHAR* buffer, unsigned bufferLen) } -void WindowRsb::open(thread_db* tdbb, jrd_req* request) +void WindowRsb::open(thread_db* tdbb, jrd_req* /*request*/) { SET_TDBB(tdbb); @@ -87,7 +87,7 @@ void WindowRsb::close(thread_db* tdbb) } -bool WindowRsb::get(thread_db* tdbb, jrd_req* request) +bool WindowRsb::get(thread_db* tdbb, jrd_req* /*request*/) { SET_TDBB(tdbb); diff --git a/src/jrd/dyn.epp b/src/jrd/dyn.epp index 6aef79c033..27f62ea07e 100644 --- a/src/jrd/dyn.epp +++ b/src/jrd/dyn.epp @@ -2290,7 +2290,7 @@ static void dyn_user(Global* gbl, const UCHAR** ptr) * **************************************/ thread_db* tdbb = JRD_get_thread_data(); - Database* const dbb = tdbb->getDatabase(); + //Database* const dbb = tdbb->getDatabase(); jrd_tra* const tra = tdbb->getTransaction(); ISC_STATUS_ARRAY status; diff --git a/src/jrd/met.epp b/src/jrd/met.epp index e3e2fcbefe..719982374e 100644 --- a/src/jrd/met.epp +++ b/src/jrd/met.epp @@ -4787,7 +4787,7 @@ static jrd_nod* parse_procedure_blr(thread_db* tdbb, const SLONG length = blob->blb_length + 10; UCHAR* temp = tmp.getBuffer(length); const ULONG realLen = BLB_get_data(tdbb, blob, temp, length); - fb_assert(realLen >= length - 10 && realLen <= ULONG(MAX_USHORT)); + fb_assert(realLen >= ULONG(length) - 10 && realLen <= ULONG(MAX_USHORT)); tmp.resize(realLen); }