summaryrefslogtreecommitdiff
path: root/src/db/Db.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/db/Db.c')
-rw-r--r--src/db/Db.c150
1 files changed, 75 insertions, 75 deletions
diff --git a/src/db/Db.c b/src/db/Db.c
index eeaf220..0695500 100644
--- a/src/db/Db.c
+++ b/src/db/Db.c
@@ -1,4 +1,4 @@
-/* Db.c generated by valac 0.34.7, the Vala compiler
+/* Db.c generated by valac 0.36.6, the Vala compiler
* generated from Db.vala, do not modify */
/* Copyright 2016 Software Freedom Conservancy Inc.
@@ -71,7 +71,7 @@ void database_table_init (const gchar* filename);
void db_terminate (void);
void database_table_terminate (void);
GType db_verify_result_get_type (void) G_GNUC_CONST;
-DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version);
+DbVerifyResult db_verify_database (gchar* * app_version, gint* schema_version);
gpointer database_table_ref (gpointer instance);
void database_table_unref (gpointer instance);
GParamSpec* param_spec_database_table (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
@@ -81,7 +81,7 @@ gpointer value_get_database_table (const GValue* value);
GType database_table_get_type (void) G_GNUC_CONST;
GType version_table_get_type (void) G_GNUC_CONST;
VersionTable* version_table_get_instance (void);
-gint version_table_get_version (VersionTable* self, gchar** app_version);
+gint version_table_get_version (VersionTable* self, gchar* * app_version);
#define DATABASE_TABLE_SCHEMA_VERSION 20
#define RESOURCES_APP_VERSION _VERSION
void version_table_set_version (VersionTable* self, gint version, const gchar* app_version, const gchar* user_data);
@@ -106,8 +106,8 @@ void version_table_update_version (VersionTable* self, gint version, const gchar
void db_preconfigure (GFile* db_file) {
gchar* _tmp0_ = NULL;
- GFile* _tmp1_ = NULL;
- gchar* _tmp5_ = NULL;
+ GFile* _tmp1_;
+ gchar* _tmp5_;
#line 14 "/home/jens/Source/shotwell/src/db/Db.vala"
g_return_if_fail ((db_file == NULL) || G_IS_FILE (db_file));
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -115,8 +115,8 @@ void db_preconfigure (GFile* db_file) {
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp1_ != NULL) {
#line 118 "Db.c"
- GFile* _tmp2_ = NULL;
- gchar* _tmp3_ = NULL;
+ GFile* _tmp2_;
+ gchar* _tmp3_;
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp2_ = db_file;
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -127,7 +127,7 @@ void db_preconfigure (GFile* db_file) {
_tmp0_ = _tmp3_;
#line 129 "Db.c"
} else {
- gchar* _tmp4_ = NULL;
+ gchar* _tmp4_;
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp4_ = g_strdup (DB_IN_MEMORY_NAME);
#line 15 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -149,8 +149,8 @@ void db_preconfigure (GFile* db_file) {
void db_init (GError** error) {
- const gchar* _tmp0_ = NULL;
- const gchar* _tmp1_ = NULL;
+ const gchar* _tmp0_;
+ const gchar* _tmp1_;
#line 19 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp0_ = db_filename;
#line 19 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -182,17 +182,17 @@ GType db_verify_result_get_type (void) {
}
-DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
+DbVerifyResult db_verify_database (gchar* * app_version, gint* schema_version) {
gchar* _vala_app_version = NULL;
gint _vala_schema_version = 0;
DbVerifyResult result = 0;
VersionTable* version_table = NULL;
- VersionTable* _tmp0_ = NULL;
- VersionTable* _tmp1_ = NULL;
+ VersionTable* _tmp0_;
+ VersionTable* _tmp1_;
gchar* _tmp2_ = NULL;
- gint _tmp3_ = 0;
- gint _tmp4_ = 0;
- gint _tmp7_ = 0;
+ gint _tmp3_;
+ gint _tmp4_;
+ gint _tmp7_;
#line 36 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp0_ = version_table_get_instance ();
#line 36 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -212,8 +212,8 @@ DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
#line 39 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp4_ >= 0) {
#line 215 "Db.c"
- gint _tmp5_ = 0;
- const gchar* _tmp6_ = NULL;
+ gint _tmp5_;
+ const gchar* _tmp6_;
#line 40 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp5_ = _vala_schema_version;
#line 40 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -227,8 +227,8 @@ DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
#line 42 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp7_ == -1) {
#line 230 "Db.c"
- VersionTable* _tmp8_ = NULL;
- gchar* _tmp9_ = NULL;
+ VersionTable* _tmp8_;
+ gchar* _tmp9_;
#line 44 "/home/jens/Source/shotwell/src/db/Db.vala"
g_debug ("Db.vala:44: Creating database schema version %d for app version %s", DATABASE_TABLE_SCHEMA_VERSION, RESOURCES_APP_VERSION);
#line 46 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -245,7 +245,7 @@ DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
_vala_schema_version = DATABASE_TABLE_SCHEMA_VERSION;
#line 247 "Db.c"
} else {
- gint _tmp10_ = 0;
+ gint _tmp10_;
#line 49 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp10_ = _vala_schema_version;
#line 49 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -274,16 +274,16 @@ DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
return result;
#line 276 "Db.c"
} else {
- gint _tmp11_ = 0;
+ gint _tmp11_;
#line 52 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp11_ = _vala_schema_version;
#line 52 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp11_ < DATABASE_TABLE_SCHEMA_VERSION) {
#line 283 "Db.c"
DbVerifyResult _result_ = 0;
- gint _tmp12_ = 0;
- DbVerifyResult _tmp13_ = 0;
- DbVerifyResult _tmp14_ = 0;
+ gint _tmp12_;
+ DbVerifyResult _tmp13_;
+ DbVerifyResult _tmp14_;
#line 54 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp12_ = _vala_schema_version;
#line 54 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -349,38 +349,38 @@ DbVerifyResult db_verify_database (gchar** app_version, gint* schema_version) {
DbVerifyResult db_upgrade_database (gint input_version) {
DbVerifyResult result = 0;
- gint _tmp0_ = 0;
+ gint _tmp0_;
gint version = 0;
- gint _tmp1_ = 0;
- gint _tmp2_ = 0;
- gint _tmp3_ = 0;
- gboolean _tmp4_ = FALSE;
- gboolean _tmp6_ = FALSE;
- gboolean _tmp8_ = FALSE;
- gboolean _tmp10_ = FALSE;
- gboolean _tmp12_ = FALSE;
- gboolean _tmp14_ = FALSE;
- gboolean _tmp16_ = FALSE;
- gboolean _tmp18_ = FALSE;
+ gint _tmp1_;
+ gint _tmp2_;
+ gint _tmp3_;
+ gboolean _tmp4_;
+ gboolean _tmp6_;
+ gboolean _tmp8_;
+ gboolean _tmp10_;
+ gboolean _tmp12_;
+ gboolean _tmp14_;
+ gboolean _tmp16_;
+ gboolean _tmp18_;
gboolean _tmp20_ = FALSE;
- gboolean _tmp21_ = FALSE;
- gboolean _tmp24_ = FALSE;
- gboolean _tmp26_ = FALSE;
- gboolean _tmp27_ = FALSE;
- gboolean _tmp29_ = FALSE;
- gboolean _tmp31_ = FALSE;
- gboolean _tmp33_ = FALSE;
- gint _tmp35_ = 0;
- gint _tmp36_ = 0;
- gboolean _tmp37_ = FALSE;
- gboolean _tmp39_ = FALSE;
- gboolean _tmp41_ = FALSE;
- gint _tmp43_ = 0;
- gint _tmp46_ = 0;
- VersionTable* _tmp47_ = NULL;
- VersionTable* _tmp48_ = NULL;
- gint _tmp49_ = 0;
- gint _tmp50_ = 0;
+ gboolean _tmp21_;
+ gboolean _tmp24_;
+ gboolean _tmp26_;
+ gboolean _tmp27_;
+ gboolean _tmp29_;
+ gboolean _tmp31_;
+ gboolean _tmp33_;
+ gint _tmp35_;
+ gint _tmp36_;
+ gboolean _tmp37_;
+ gboolean _tmp39_;
+ gboolean _tmp41_;
+ gint _tmp43_;
+ gint _tmp46_;
+ VersionTable* _tmp47_;
+ VersionTable* _tmp48_;
+ gint _tmp49_;
+ gint _tmp50_;
#line 63 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp0_ = input_version;
#line 63 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -408,7 +408,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 83 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp4_) {
#line 411 "Db.c"
- gboolean _tmp5_ = FALSE;
+ gboolean _tmp5_;
#line 84 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:84: upgrade_database: adding flags column to PhotoTable");
#line 85 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -429,7 +429,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 100 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp6_) {
#line 432 "Db.c"
- gboolean _tmp7_ = FALSE;
+ gboolean _tmp7_;
#line 101 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:101: upgrade_database: adding file_format column to PhotoTable");
#line 102 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -450,7 +450,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 113 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp8_) {
#line 453 "Db.c"
- gboolean _tmp9_ = FALSE;
+ gboolean _tmp9_;
#line 114 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:114: upgrade_database: adding title column to PhotoTable");
#line 115 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -471,7 +471,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 126 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp10_) {
#line 474 "Db.c"
- gboolean _tmp11_ = FALSE;
+ gboolean _tmp11_;
#line 127 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:127: upgrade_database: adding backlinks column to PhotoTable");
#line 128 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -492,7 +492,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 146 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp12_) {
#line 495 "Db.c"
- gboolean _tmp13_ = FALSE;
+ gboolean _tmp13_;
#line 147 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:147: upgrade_database: adding time_reimported column to PhotoT" \
"able");
@@ -512,7 +512,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 152 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp14_) {
#line 514 "Db.c"
- gboolean _tmp15_ = FALSE;
+ gboolean _tmp15_;
#line 153 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:153: upgrade_database: adding editable_id column to PhotoTable");
#line 154 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -533,7 +533,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 170 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp16_) {
#line 535 "Db.c"
- gboolean _tmp17_ = FALSE;
+ gboolean _tmp17_;
#line 171 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:171: upgrade_database: adding rating column to PhotoTable");
#line 172 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -552,7 +552,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 182 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp18_) {
#line 554 "Db.c"
- gboolean _tmp19_ = FALSE;
+ gboolean _tmp19_;
#line 183 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:183: upgrade_database: adding metadata_dirty column to PhotoTa" \
"ble");
@@ -574,7 +574,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 195 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp21_) {
#line 575 "Db.c"
- gboolean _tmp22_ = FALSE;
+ gboolean _tmp22_;
#line 195 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp22_ = database_table_has_column ("VideoTable", "flags");
#line 195 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -588,7 +588,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 195 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp20_) {
#line 589 "Db.c"
- gboolean _tmp23_ = FALSE;
+ gboolean _tmp23_;
#line 196 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:196: upgrade_database: adding flags column to VideoTable");
#line 197 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -609,7 +609,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 208 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp24_) {
#line 610 "Db.c"
- gboolean _tmp25_ = FALSE;
+ gboolean _tmp25_;
#line 209 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:209: upgrade_database: adding primary_source_id column to Even" \
"tTable");
@@ -643,7 +643,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 233 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp27_) {
#line 643 "Db.c"
- gboolean _tmp28_ = FALSE;
+ gboolean _tmp28_;
#line 234 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:234: upgrade_database: adding developer column to PhotoTable");
#line 235 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -662,7 +662,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 239 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp29_) {
#line 662 "Db.c"
- gboolean _tmp30_ = FALSE;
+ gboolean _tmp30_;
#line 240 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:240: upgrade_database: adding develop_shotwell_id column to Ph" \
"otoTable");
@@ -682,7 +682,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 245 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp31_) {
#line 681 "Db.c"
- gboolean _tmp32_ = FALSE;
+ gboolean _tmp32_;
#line 246 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:246: upgrade_database: adding develop_camera_id column to Phot" \
"oTable");
@@ -702,7 +702,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 251 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp33_) {
#line 700 "Db.c"
- gboolean _tmp34_ = FALSE;
+ gboolean _tmp34_;
#line 252 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:252: upgrade_database: adding develop_embedded_id column to Ph" \
"otoTable");
@@ -746,7 +746,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 302 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp37_) {
#line 743 "Db.c"
- gboolean _tmp38_ = FALSE;
+ gboolean _tmp38_;
#line 303 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:303: upgrade_database: adding comment column to PhotoTable");
#line 304 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -765,7 +765,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 307 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp39_) {
#line 762 "Db.c"
- gboolean _tmp40_ = FALSE;
+ gboolean _tmp40_;
#line 308 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:308: upgrade_database: adding comment column to VideoTable");
#line 309 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -786,7 +786,7 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 320 "/home/jens/Source/shotwell/src/db/Db.vala"
if (!_tmp41_) {
#line 783 "Db.c"
- gboolean _tmp42_ = FALSE;
+ gboolean _tmp42_;
#line 321 "/home/jens/Source/shotwell/src/db/Db.vala"
g_message ("Db.vala:321: upgrade_database: adding comment column to EventTable");
#line 322 "/home/jens/Source/shotwell/src/db/Db.vala"
@@ -807,8 +807,8 @@ DbVerifyResult db_upgrade_database (gint input_version) {
#line 337 "/home/jens/Source/shotwell/src/db/Db.vala"
if (_tmp43_ < 19) {
#line 804 "Db.c"
- Application* _tmp44_ = NULL;
- Application* _tmp45_ = NULL;
+ Application* _tmp44_;
+ Application* _tmp45_;
#line 338 "/home/jens/Source/shotwell/src/db/Db.vala"
_tmp44_ = application_get_instance ();
#line 338 "/home/jens/Source/shotwell/src/db/Db.vala"