diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:18:58 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-11-10 10:31:30 +0100 |
commit | 5678a4ce9eee64cafdbdb4fc1290535f9e03208f (patch) | |
tree | cd2be82261e5784f86d541ce7e70abc8b722230d /libreofficekit/source/gtk/tilebuffer.cxx | |
parent | af9c3fa41ba16ae4dc5e7ccbf626c8701ae0aa19 (diff) |
loplugin:nullptr (automatic rewrite)
Change-Id: Ibdb6409664cdf9499b6fec95c5de3549887b8106
Diffstat (limited to 'libreofficekit/source/gtk/tilebuffer.cxx')
-rw-r--r-- | libreofficekit/source/gtk/tilebuffer.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libreofficekit/source/gtk/tilebuffer.cxx b/libreofficekit/source/gtk/tilebuffer.cxx index 330b44675c9c..675384c4582e 100644 --- a/libreofficekit/source/gtk/tilebuffer.cxx +++ b/libreofficekit/source/gtk/tilebuffer.cxx @@ -38,7 +38,7 @@ void Tile::setPixbuf(GdkPixbuf *buffer) if (m_pBuffer == buffer) return; g_clear_object(&m_pBuffer); - if (buffer != NULL) + if (buffer != nullptr) g_object_ref(buffer); m_pBuffer = buffer; } @@ -60,7 +60,7 @@ void TileBuffer::setInvalid(int x, int y, float fZoom, GTask* task, GThreadPool* lokThreadPool) { int index = x * m_nWidth + y; - GError* error = NULL; + GError* error = nullptr; if (m_mTiles.find(index) != m_mTiles.end()) { m_mTiles[index].valid = false; @@ -71,7 +71,7 @@ void TileBuffer::setInvalid(int x, int y, float fZoom, GTask* task, pLOEvent->m_fPaintTileZoom = fZoom; g_task_set_task_data(task, pLOEvent, LOEvent::destroy); g_thread_pool_push(lokThreadPool, g_object_ref(task), &error); - if (error != NULL) + if (error != nullptr) { g_warning("Unable to call LOK_PAINT_TILE: %s", error->message); g_clear_error(&error); @@ -83,12 +83,12 @@ Tile& TileBuffer::getTile(int x, int y, GTask* task, GThreadPool* lokThreadPool) { int index = x * m_nWidth + y; - GError* error = NULL; + GError* error = nullptr; if (m_mTiles.find(index) != m_mTiles.end() && !m_mTiles[index].valid) { g_thread_pool_push(lokThreadPool, g_object_ref(task), &error); - if (error != NULL) + if (error != nullptr) { g_warning("Unable to call LOK_PAINT_TILE: %s", error->message); g_clear_error(&error); @@ -98,7 +98,7 @@ Tile& TileBuffer::getTile(int x, int y, GTask* task, else if(m_mTiles.find(index) == m_mTiles.end()) { g_thread_pool_push(lokThreadPool, g_object_ref(task), &error); - if (error != NULL) + if (error != nullptr) { g_warning("Unable to call LOK_PAINT_TILE: %s", error->message); g_clear_error(&error); |