From a170b53b6935311afc546d637df5ce662652247d Mon Sep 17 00:00:00 2001 From: Marco van Wieringen Date: Wed, 7 Apr 2010 20:08:43 +0200 Subject: [PATCH] Fix stupid inverted logic --- bacula/src/cats/dbi.c | 2 +- bacula/src/cats/mysql.c | 2 +- bacula/src/cats/postgresql.c | 2 +- bacula/src/cats/sqlite.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bacula/src/cats/dbi.c b/bacula/src/cats/dbi.c index 5ed4359f4f..a9d90ee744 100644 --- a/bacula/src/cats/dbi.c +++ b/bacula/src/cats/dbi.c @@ -1280,7 +1280,7 @@ int my_dbi_sql_insert_id(B_DB *mdb, const char *query, const char *table_name) /* * First execute the insert query and then retrieve the currval. */ - if (!my_dbi_query(mdb, query)) { + if (my_dbi_query(mdb, query)) { return 0; } diff --git a/bacula/src/cats/mysql.c b/bacula/src/cats/mysql.c index f283416204..5124dd2a90 100644 --- a/bacula/src/cats/mysql.c +++ b/bacula/src/cats/mysql.c @@ -385,7 +385,7 @@ int my_mysql_sql_insert_id(B_DB *mdb, const char *query, const char *table_name) /* * First execute the insert query and then retrieve the currval. */ - if (!mysql_query(mdb->db, query)) { + if (mysql_query(mdb->db, query)) { return 0; } diff --git a/bacula/src/cats/postgresql.c b/bacula/src/cats/postgresql.c index 69028f4dbd..74ced4d6e4 100644 --- a/bacula/src/cats/postgresql.c +++ b/bacula/src/cats/postgresql.c @@ -662,7 +662,7 @@ int my_postgresql_insert_id(B_DB *mdb, const char *query, const char *table_name /* * First execute the insert query and then retrieve the currval. */ - if (!my_postgresql_query(mdb, query)) { + if (my_postgresql_query(mdb, query)) { return 0; } diff --git a/bacula/src/cats/sqlite.c b/bacula/src/cats/sqlite.c index ea7299498f..96e131c7a9 100644 --- a/bacula/src/cats/sqlite.c +++ b/bacula/src/cats/sqlite.c @@ -505,7 +505,7 @@ int my_sqlite_sql_insert_id(B_DB *mdb, const char *query, const char *table_name /* * First execute the insert query and then retrieve the currval. */ - if (!my_sqlite_query(mdb, query)) { + if (my_sqlite_query(mdb, query)) { return 0; } -- 2.39.5