/[gentoo-x86]/media-gfx/showimg/files/showimg-0.9.5-libpqxx-2.6.9.diff
Gentoo

Contents of /media-gfx/showimg/files/showimg-0.9.5-libpqxx-2.6.9.diff

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download) (as text)
Fri Nov 13 17:10:15 2009 UTC (10 years, 8 months ago) by ssuominen
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +0 -0 lines
File MIME type: text/x-diff
FILE REMOVED
Remove masked showimg, doesn't compile, deps on kdelibs:3.5

1 diff -Naur showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.cpp showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.cpp
2 --- showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.cpp 2006-01-07 19:47:46.000000000 +1100
3 +++ showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.cpp 2008-11-12 18:11:01.000000000 +1100
4 @@ -16,6 +16,8 @@
5 #include <kexidb/error.h>
6 #include <klocale.h>
7 #include <string>
8 +#include <pqxx/nontransaction>
9 +#include <pqxx/transaction>
10
11 using namespace KexiDB;
12
13 @@ -26,6 +28,7 @@
14 data = new pqxx::nontransaction(*static_cast<pqxxSqlConnection*>(conn)->m_pqxxsql /* todo: add name? */);
15 else
16 data = new pqxx::transaction<>(*static_cast<pqxxSqlConnection*>(conn)->m_pqxxsql /* todo: add name? */);
17 +
18 if (!static_cast<pqxxSqlConnection*>(conn)->m_trans) {
19 static_cast<pqxxSqlConnection*>(conn)->m_trans = this;
20 }
21 @@ -248,7 +251,8 @@
22 // m_trans = new pqxx::nontransaction(*m_pqxxsql);
23
24 //Create a result object through the transaction
25 - m_res = new pqxx::result(m_trans->data->exec(statement.utf8()));
26 + std::string query(statement.utf8());
27 + m_res = new pqxx::result(m_trans->data->exec(query));
28
29 //Commit the transaction
30 if (implicityStarted) {
31 diff -Naur showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.h showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.h
32 --- showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.h 2006-01-07 19:47:46.000000000 +1100
33 +++ showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxconnection.h 2008-11-12 18:10:06.000000000 +1100
34 @@ -16,7 +16,9 @@
35
36 #include <kexidb/connection.h>
37 #include "pqxxcursor.h"
38 -#include <pqxx/all.h>
39 +#include <pqxx/result>
40 +#include <pqxx/connection>
41 +#include <pqxx/transaction_base>
42
43
44 namespace KexiDB
45 diff -Naur showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.cpp showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.cpp
46 --- showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.cpp 2006-01-07 19:47:46.000000000 +1100
47 +++ showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.cpp 2008-11-12 18:10:11.000000000 +1100
48 @@ -11,6 +11,7 @@
49 //
50 #include "pqxxcursor.h"
51 #include "pqxxconnection.h"
52 +#include <pqxx/nontransaction>
53
54 #include <kexidb/error.h>
55 #include <kexidb/global.h>
56 @@ -84,7 +85,8 @@
57 m_implicityStarted = true;
58 }
59
60 - m_res = new pqxx::result(((pqxxSqlConnection*)connection())->m_trans->data->exec(statement.utf8()));
61 + std::string std_statement(statement.utf8());
62 + m_res = new pqxx::result(((pqxxSqlConnection*)connection())->m_trans->data->exec(std_statement));
63 ((pqxxSqlConnection*)connection())
64 ->drv_commitTransaction(((pqxxSqlConnection*)connection())->m_trans);
65 // my_conn->m_trans->commit();
66 diff -Naur showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.h showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.h
67 --- showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.h 2006-01-07 19:47:46.000000000 +1100
68 +++ showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxcursor.h 2008-11-12 18:10:16.000000000 +1100
69 @@ -15,7 +15,8 @@
70 #include <kexidb/cursor.h>
71 #include <kexidb/connection.h>
72
73 -#include <pqxx/all.h>
74 +#include <pqxx/result>
75 +#include <pqxx/connection>
76
77 namespace KexiDB {
78
79 diff -Naur showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxdriver.cpp showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxdriver.cpp
80 --- showimg-0.9.5-orig/showimg/kexi/kexidb/drivers/pqxx/pqxxdriver.cpp 2006-01-07 19:47:46.000000000 +1100
81 +++ showimg-0.9.5-libpqxx/showimg/kexi/kexidb/drivers/pqxx/pqxxdriver.cpp 2008-11-12 18:10:23.000000000 +1100
82 @@ -22,6 +22,7 @@
83 #include <kexidb/driver_p.h>
84 #include "pqxxdriver.h"
85 #include "pqxxconnection.h"
86 +#include <pqxx/util>
87 #include <string>
88
89 #include <kdebug.h>
90 @@ -132,14 +133,17 @@
91 //
92 QString pqxxSqlDriver::escapeString( const QString& str) const
93 {
94 - return QString(pqxx::Quote(str.ascii()).c_str());
95 + // pqxx::sqlesc has been marked as deprecated
96 + // in libpqxx 2.6, but this will get us through
97 + // until showimg is killed or upgraded to a new kexi
98 + return QString(pqxx::sqlesc(str.ascii()).c_str());
99 }
100
101 //==================================================================================
102 //
103 QCString pqxxSqlDriver::escapeString( const QCString& str) const
104 {
105 - return QCString(pqxx::Quote(QString(str).ascii()).c_str());
106 + return QCString(pqxx::sqlesc(QString(str).ascii()).c_str());
107 }
108
109 //==================================================================================

  ViewVC Help
Powered by ViewVC 1.1.20