Fix dbresult and leaky tile provider