Skip to content
Permalink
Browse files

Rename QgsSqlite3Mprintf to qgs_sqlite3_mprintf

It's not a class name
  • Loading branch information
m-kuhn authored and nyalldawson committed Aug 18, 2020
1 parent fbd80cc commit 97fd45aebb9b18bfe70a97464a7570d49cca9ec7
@@ -127,7 +127,7 @@ QSet<QString> QgsSqliteUtils::uniqueFields( sqlite3 *connection, const QString &
char *zErrMsg = 0;
std::vector<std::string> rows;
QByteArray tableNameUtf8 = quotedIdentifier( tableName ).toUtf8();
QString sql = QgsSqlite3Mprintf( "select sql from sqlite_master "
QString sql = qgs_sqlite3_mprintf( "select sql from sqlite_master "
"where type='table' and name=%q", tableNameUtf8.constData() );
auto cb = [ ](
void *data /* Data provided in the 4th argument of sqlite3_exec() */,
@@ -173,7 +173,7 @@ QSet<QString> QgsSqliteUtils::uniqueFields( sqlite3 *connection, const QString &
rows.clear();

// Search indexes:
sql = QgsSqlite3Mprintf( "SELECT sql FROM sqlite_master WHERE type='index' AND"
sql = qgs_sqlite3_mprintf( "SELECT sql FROM sqlite_master WHERE type='index' AND"
" tbl_name='%q' AND sql LIKE 'CREATE UNIQUE INDEX%%'", tableNameUtf8.constData() );
rc = sqlite3_exec( connection, sql.toUtf8(), cb, ( void * )&rows, &zErrMsg );
if ( rc != SQLITE_OK )
@@ -309,7 +309,7 @@ QStringList QgsSqliteUtils::systemTables()
<< QStringLiteral( "ElementaryGeometries" );
}

QString QgsSqlite3Mprintf( const char *format, ... )
QString qgs_sqlite3_mprintf( const char *format, ... )
{
va_list ap;
va_start( ap, format );
@@ -161,7 +161,7 @@ class CORE_EXPORT sqlite3_database_unique_ptr : public std::unique_ptr< sqlite3,
* \note not available in Python bindings.
* \since QGIS 3.2
*/
QString CORE_EXPORT QgsSqlite3Mprintf( const char *format, ... );
QString CORE_EXPORT qgs_sqlite3_mprintf( const char *format, ... );

#endif

0 comments on commit 97fd45a

Please sign in to comment.
You can’t perform that action at this time.