summaryrefslogtreecommitdiff
path: root/plugins/MirOTR/src/entities.cpp
diff options
context:
space:
mode:
authorGoraf <22941576+Goraf@users.noreply.github.com>2017-11-13 15:03:31 +0100
committerGoraf <22941576+Goraf@users.noreply.github.com>2017-11-13 15:07:33 +0100
commita7c24ca48995cf2bf436156302f96b91bf135409 (patch)
tree953835509ff1b778833e78fd7b74b05e05e77c84 /plugins/MirOTR/src/entities.cpp
parent591ec17b1c99db7f120c22ca9fb20ae05fe78325 (diff)
Code modernize ...
* replace 0/NULL with nullptr [using clang-tidy]
Diffstat (limited to 'plugins/MirOTR/src/entities.cpp')
-rw-r--r--plugins/MirOTR/src/entities.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/plugins/MirOTR/src/entities.cpp b/plugins/MirOTR/src/entities.cpp
index f049ad0b88..62b0865b73 100644
--- a/plugins/MirOTR/src/entities.cpp
+++ b/plugins/MirOTR/src/entities.cpp
@@ -277,7 +277,7 @@ static const char *get_named_entity(const char *name)
sizeof(named_entities) / sizeof(*named_entities),
sizeof(*named_entities), cmp);
- return entity ? entity[1] : NULL;
+ return entity ? entity[1] : nullptr;
}
static size_t putc_utf8(unsigned long cp, char *buffer)
@@ -325,7 +325,7 @@ static bool parse_entity(const char *current, char **to,
if(current[1] == '#')
{
- char *tail = NULL;
+ char *tail = nullptr;
errno = 0;
bool hex = current[2] == 'x' || current[2] == 'X';
@@ -395,7 +395,7 @@ char* encode_html_entities_utf8(const char *src)
{
const char *pos = strpbrk(src, "&<>\"\r");
if (!pos)
- return NULL;
+ return nullptr;
const char *start = src;
std::string buf;