From ab1487672afb5180bd17c9d26b35196bd06f6cda Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Thu, 28 Jul 2011 09:45:36 +0200 Subject: Add value_traits specializations for std::vector This allows using it as a buffer for BLOB mapping. --- pgsql/types/driver.cxx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'pgsql/types/driver.cxx') diff --git a/pgsql/types/driver.cxx b/pgsql/types/driver.cxx index 745d2ee..d6d675c 100644 --- a/pgsql/types/driver.cxx +++ b/pgsql/types/driver.cxx @@ -51,8 +51,7 @@ main (int argc, char* argv[]) o.varchar_ = medium_str; o.text_ = long_str; - buffer long_buf (long_str.c_str (), long_str.size ()); - o.bytea_ = long_buf; + o.bytea_.assign (long_str.c_str (), long_str.c_str () + long_str.size ()); unsigned char varbit_buf[8] = {1, 3, 1, 3, 1, 3, 1, 3}; o.varbit_.size = 52; -- cgit v1.1