~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/session.cc

  • Committer: Brian Aker
  • Date: 2011-02-16 02:39:43 UTC
  • mfrom: (2171.1.3 drizzle-staging)
  • Revision ID: brian@tangent.org-20110216023943-z4lxkjvknnrrncr2
Merge of all fixes related to errors, schemas, etc.

Show diffs side-by-side

added added

removed removed

Lines of Context:
45
45
#include "drizzled/plugin/query_rewrite.h"
46
46
#include "drizzled/probes.h"
47
47
#include "drizzled/table_proto.h"
48
 
#include "drizzled/db.h"
49
48
#include "drizzled/pthread_globals.h"
50
49
#include "drizzled/transaction_services.h"
51
50
#include "drizzled/drizzled.h"
86
85
 
87
86
#include "drizzled/util/backtrace.h"
88
87
 
 
88
#include <drizzled/schema.h>
 
89
 
89
90
using namespace std;
90
91
 
91
92
namespace fs=boost::filesystem;
598
599
*/
599
600
bool Session::isViewable(identifier::User::const_reference user_arg) const
600
601
{
601
 
  return plugin::Authorization::isAuthorized(user_arg, this, false);
 
602
  return plugin::Authorization::isAuthorized(user_arg, *this, false);
602
603
}
603
604
 
604
605
 
641
642
                        const std::string &in_db)
642
643
{
643
644
  bool is_authenticated=
644
 
    plugin::Authentication::isAuthenticated(user(), passwd_str);
 
645
    plugin::Authentication::isAuthenticated(*user(), passwd_str);
645
646
 
646
647
  if (is_authenticated != true)
647
648
  {
654
655
  if (not in_db.empty())
655
656
  {
656
657
    identifier::Schema identifier(in_db);
657
 
    if (change_db(this, identifier))
 
658
    if (schema::change(*this, identifier))
658
659
    {
659
660
      /* change_db() has pushed the error message. */
660
661
      return false;