Skip to content
This repository has been archived by the owner on Sep 15, 2022. It is now read-only.

Commit

Permalink
Don't offer debugging options to non-superusers on
Browse files Browse the repository at this point in the history
Postgres Plus Advanced Server < 8.4 which doesn't 
have support for user debugging [Ashesh Vashi]

git-svn-id: svn://svn.pgadmin.org/branches/REL-1_10_0_PATCHES@8293 a7884b65-44f6-0310-8a51-81a127f17b15
  • Loading branch information
dpage committed Apr 22, 2010
1 parent f73710b commit 898802d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG
Expand Up @@ -36,6 +36,9 @@ Changes

Date Dev Ver Change details
---------- --- ------ --------------
2010-04-22 DP 1.10.3 Don't offer debugging options to non-superusers on
Postgres Plus Advanced Server < 8.4 which doesn't
have support for user debugging [Ashesh Vashi]
2010-04-21 GL 1.10.3 Fix the saving and reverse engineering of parameters for
database, table, and function, according to a report
from Erwin Brandstetter.
Expand Down
4 changes: 4 additions & 0 deletions pgadmin/debugger/debugger.cpp
Expand Up @@ -114,6 +114,10 @@ bool debuggerFactory::CheckEnable(pgObject *obj)
if (!obj->GetServer() || !(obj->GetServer()->GetSuperUser() || obj->GetServer()->GetUsername() == obj->GetOwner()))
return false;

// EnterpriseDB 8.3 or earlier does not support debugging by the non-superuser
if (!obj->GetServer()->GetSuperUser() && !obj->GetConnection()->EdbMinimumVersion(8, 4))
return false;

if (!obj->IsCollection())
{
switch (obj->GetMetaType())
Expand Down

0 comments on commit 898802d

Please sign in to comment.