aboutsummaryrefslogtreecommitdiff
path: root/odb/mysql/result.txx
diff options
context:
space:
mode:
authorBoris Kolpackov <boris@codesynthesis.com>2010-08-16 11:45:54 +0200
committerBoris Kolpackov <boris@codesynthesis.com>2010-08-16 11:45:54 +0200
commitc803163e7c8af93828809cd98a12c14d36ee96c4 (patch)
treecbbb94fa1f6fdb66f3ffb638b9af92ccc2e3f22d /odb/mysql/result.txx
parentbad675ea0e17b6eb18d75ddc403b81ff5f76ad25 (diff)
Add pointer guard for naked pointer
Diffstat (limited to 'odb/mysql/result.txx')
-rw-r--r--odb/mysql/result.txx8
1 files changed, 4 insertions, 4 deletions
diff --git a/odb/mysql/result.txx b/odb/mysql/result.txx
index debb725..d81f058 100644
--- a/odb/mysql/result.txx
+++ b/odb/mysql/result.txx
@@ -28,9 +28,9 @@ namespace odb
{
if (!this->end_)
{
- this->current_ = traits::create ();
- traits::init (pointer_ops::get_ref (this->current_),
- statements_.image ());
+ pointer_type p (traits::create ());
+ current (p);
+ traits::init (pointer_traits::get_ref (p), statements_.image ());
}
}
@@ -46,7 +46,7 @@ namespace odb
void result_impl<T>::
next ()
{
- this->current_ = pointer_type ();
+ this->current (pointer_type ());
query_statement::result r (statement_->fetch ());
switch (r)