summaryrefslogtreecommitdiffstats
path: root/rbutil/rbutilqt/base/bootloaderinstalltcc.cpp
diff options
context:
space:
mode:
authorDominik Riebeling <Dominik.Riebeling@gmail.com>2020-11-19 20:36:57 +0100
committerDominik Riebeling <Dominik.Riebeling@gmail.com>2020-11-19 21:32:41 +0100
commit12764781c6053898925484dee07e71a52abc4f26 (patch)
tree3f89294c8053770ac4e1e4769bfd28a234554ee6 /rbutil/rbutilqt/base/bootloaderinstalltcc.cpp
parentf608de723c863abc0e32cd7584c046eceb910d78 (diff)
downloadrockbox-12764781c6.tar.gz
rockbox-12764781c6.tar.bz2
rockbox-12764781c6.zip
rbutil: Modernize code to use C++11 nullptr.
Change-Id: I112cf95122a896cdb30a823b4c1f49831273dc7e
Diffstat (limited to 'rbutil/rbutilqt/base/bootloaderinstalltcc.cpp')
-rw-r--r--rbutil/rbutilqt/base/bootloaderinstalltcc.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/rbutil/rbutilqt/base/bootloaderinstalltcc.cpp b/rbutil/rbutilqt/base/bootloaderinstalltcc.cpp
index e0bfbe3cf2..1551d7c45d 100644
--- a/rbutil/rbutilqt/base/bootloaderinstalltcc.cpp
+++ b/rbutil/rbutilqt/base/bootloaderinstalltcc.cpp
@@ -57,7 +57,7 @@ bool BootloaderInstallTcc::install(void)
void BootloaderInstallTcc::installStage2(void)
{
- unsigned char *of_buf, *boot_buf = NULL, *patched_buf = NULL;
+ unsigned char *of_buf, *boot_buf = nullptr, *patched_buf = nullptr;
int n, of_size, boot_size, patched_size;
char errstr[200];
bool ret = false;
@@ -76,7 +76,7 @@ void BootloaderInstallTcc::installStage2(void)
/* Load original firmware file */
of_buf = file_read(m_offile.toLocal8Bit().data(), &of_size);
- if (of_buf == NULL)
+ if (of_buf == nullptr)
{
emit logItem(errstr, LOGERROR);
emit logItem(tr("Could not load %1").arg(m_offile), LOGERROR);
@@ -93,7 +93,7 @@ void BootloaderInstallTcc::installStage2(void)
/* Load bootloader file */
boot_buf = file_read(bootfile.toLocal8Bit().data(), &boot_size);
- if (boot_buf == NULL)
+ if (boot_buf == nullptr)
{
emit logItem(errstr, LOGERROR);
emit logItem(tr("Could not load %1").arg(bootfile), LOGERROR);
@@ -105,7 +105,7 @@ void BootloaderInstallTcc::installStage2(void)
patched_buf = patch_firmware_tcc(of_buf, of_size, boot_buf, boot_size,
&patched_size);
- if (patched_buf == NULL)
+ if (patched_buf == nullptr)
{
emit logItem(errstr, LOGERROR);
emit logItem(tr("Could not patch firmware"), LOGERROR);