summaryrefslogtreecommitdiff
path: root/drivers/png
diff options
context:
space:
mode:
authorlupoDharkael <izhe@hotmail.es>2020-04-02 01:20:12 +0200
committerlupoDharkael <izhe@hotmail.es>2020-04-02 13:38:00 +0200
commit95a1400a2ac9de1a29fa305f45b928ce8e3044bd (patch)
treebe0cd59e5a90926e9d653fed9f3b1b77e735ca2f /drivers/png
parent5f11e1557156617366d2c316a97716172103980d (diff)
Replace NULL with nullptr
Diffstat (limited to 'drivers/png')
-rw-r--r--drivers/png/png_driver_common.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/png/png_driver_common.cpp b/drivers/png/png_driver_common.cpp
index efd488fd5c..f17abcb54c 100644
--- a/drivers/png/png_driver_common.cpp
+++ b/drivers/png/png_driver_common.cpp
@@ -110,7 +110,7 @@ Error png_to_image(const uint8_t *p_source, size_t p_size, Ref<Image> p_image) {
uint8_t *writer = buffer.ptrw();
// read image data to buffer and release libpng resources
- success = png_image_finish_read(&png_img, NULL, writer, stride, NULL);
+ success = png_image_finish_read(&png_img, nullptr, writer, stride, nullptr);
ERR_FAIL_COND_V_MSG(check_error(png_img), ERR_FILE_CORRUPT, png_img.message);
ERR_FAIL_COND_V(!success, ERR_FILE_CORRUPT);
@@ -175,7 +175,7 @@ Error image_to_png(const Ref<Image> &p_image, Vector<uint8_t> &p_buffer) {
uint8_t *writer = p_buffer.ptrw();
success = png_image_write_to_memory(&png_img, &writer[buffer_offset],
- &compressed_size, 0, reader, 0, NULL);
+ &compressed_size, 0, reader, 0, nullptr);
ERR_FAIL_COND_V_MSG(check_error(png_img), FAILED, png_img.message);
}
if (!success) {
@@ -189,7 +189,7 @@ Error image_to_png(const Ref<Image> &p_image, Vector<uint8_t> &p_buffer) {
uint8_t *writer = p_buffer.ptrw();
success = png_image_write_to_memory(&png_img, &writer[buffer_offset],
- &compressed_size, 0, reader, 0, NULL);
+ &compressed_size, 0, reader, 0, nullptr);
ERR_FAIL_COND_V_MSG(check_error(png_img), FAILED, png_img.message);
ERR_FAIL_COND_V(!success, FAILED);
}