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

Fixed CORE-5279: Granting access rights to view is broken

This commit is contained in:
Alexander Peshkov 2016-06-18 10:30:43 +03:00
parent 6d6d9d3604
commit 19254eff81

View File

@ -666,8 +666,9 @@ RecordSourceNode* RelationSourceNode::pass1(thread_db* tdbb, CompilerScratch* cs
if (relation)
{
CMP_post_access(tdbb, csb, relation->rel_security_name,
(tail->csb_view) ? tail->csb_view->rel_id : (view ? view->rel_id : 0),
int viewId = tail->csb_view ? tail->csb_view->rel_id :
view ? view->rel_id : csb->csb_view ? csb->csb_view->rel_id : 0;
CMP_post_access(tdbb, csb, relation->rel_security_name, viewId,
SCL_select, SCL_object_table, relation->rel_name);
}