forked from cory/tildefriends
Make garbage collecting blobs ease up on my phone.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4811 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
parent
542162c78a
commit
a5a00b6987
@ -1294,7 +1294,7 @@ static void _tf_ssb_rpc_delete_blobs_work(uv_work_t* work)
|
||||
sqlite3_stmt* statement;
|
||||
int64_t now = (int64_t)time(NULL) * 1000ULL;
|
||||
int64_t timestamp = now - age * 1000ULL;
|
||||
const int k_limit = 256;
|
||||
const int k_limit = 128;
|
||||
int deleted = 0;
|
||||
if (sqlite3_prepare(db,
|
||||
"DELETE FROM blobs WHERE blobs.id IN ("
|
||||
@ -1360,7 +1360,7 @@ static void _tf_ssb_rpc_start_delete_blobs(tf_ssb_t* ssb, int delay_ms)
|
||||
|
||||
void tf_ssb_rpc_start_periodic(tf_ssb_t* ssb)
|
||||
{
|
||||
_tf_ssb_rpc_start_delete_blobs(ssb, 0);
|
||||
_tf_ssb_rpc_start_delete_blobs(ssb, 30 * 1000);
|
||||
}
|
||||
|
||||
void tf_ssb_rpc_register(tf_ssb_t* ssb)
|
||||
|
Loading…
Reference in New Issue
Block a user