X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;f=src%2Fdatacache%2Fplugin_datacache_sqlite.c;h=34aa6136303d97be5ef45af2290e20abbc4eda85;hb=3d7fefedc9ba60bd8e8448efe8b628446d958536;hp=bf76f310f16c1b0b510bb9f0112cfb4bf05a0978;hpb=4a0398474db197abed243a123fb971fbeeffab4b;p=oweals%2Fgnunet.git diff --git a/src/datacache/plugin_datacache_sqlite.c b/src/datacache/plugin_datacache_sqlite.c index bf76f310f..34aa61363 100644 --- a/src/datacache/plugin_datacache_sqlite.c +++ b/src/datacache/plugin_datacache_sqlite.c @@ -116,7 +116,7 @@ sqlite_plugin_put (void *cls, "Processing `%s' of %u bytes with key `%4s' and expiration %s\n", "PUT", (unsigned int) size, GNUNET_h2s (key), GNUNET_STRINGS_relative_time_to_string (GNUNET_TIME_absolute_get_remaining (discard_time), GNUNET_YES)); - dval = (int64_t) discard_time.abs_value; + dval = (int64_t) discard_time.abs_value_us; if (dval < 0) dval = INT64_MAX; if (sq_prepare @@ -203,13 +203,13 @@ sqlite_plugin_get (void *cls, const struct GNUNET_HashCode * key, "sq_prepare"); return 0; } - ntime = (int64_t) now.abs_value; + ntime = (int64_t) now.abs_value_us; GNUNET_assert (ntime >= 0); if ((SQLITE_OK != sqlite3_bind_blob (stmt, 1, key, sizeof (struct GNUNET_HashCode), SQLITE_TRANSIENT)) || (SQLITE_OK != sqlite3_bind_int (stmt, 2, type)) || - (SQLITE_OK != sqlite3_bind_int64 (stmt, 3, now.abs_value))) + (SQLITE_OK != sqlite3_bind_int64 (stmt, 3, now.abs_value_us))) { LOG_SQLITE (plugin->dbh, GNUNET_ERROR_TYPE_ERROR | GNUNET_ERROR_TYPE_BULK, "sqlite3_bind_xxx"); @@ -256,7 +256,7 @@ sqlite_plugin_get (void *cls, const struct GNUNET_HashCode * key, sqlite3_bind_blob (stmt, 1, key, sizeof (struct GNUNET_HashCode), SQLITE_TRANSIENT)) || (SQLITE_OK != sqlite3_bind_int (stmt, 2, type)) || - (SQLITE_OK != sqlite3_bind_int64 (stmt, 3, now.abs_value))) + (SQLITE_OK != sqlite3_bind_int64 (stmt, 3, now.abs_value_us))) { LOG_SQLITE (plugin->dbh, GNUNET_ERROR_TYPE_ERROR | GNUNET_ERROR_TYPE_BULK, "sqlite3_bind_xxx"); @@ -267,7 +267,7 @@ sqlite_plugin_get (void *cls, const struct GNUNET_HashCode * key, break; size = sqlite3_column_bytes (stmt, 0); dat = sqlite3_column_blob (stmt, 0); - exp.abs_value = sqlite3_column_int64 (stmt, 1); + exp.abs_value_us = sqlite3_column_int64 (stmt, 1); psize = sqlite3_column_bytes (stmt, 2); if (0 != psize % sizeof (struct GNUNET_PeerIdentity)) { @@ -279,7 +279,7 @@ sqlite_plugin_get (void *cls, const struct GNUNET_HashCode * key, path = sqlite3_column_blob (stmt, 2); else path = NULL; - ntime = (int64_t) exp.abs_value; + ntime = (int64_t) exp.abs_value_us; if (ntime == INT64_MAX) exp = GNUNET_TIME_UNIT_FOREVER_ABS; cnt++;