From 59f8144c50765189594d5932fc25869f9ea6e265 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Sat, 19 Oct 2013 18:19:03 +0200 Subject: *: use nullptr instead of NULL --- src/InputStream.cxx | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'src/InputStream.cxx') diff --git a/src/InputStream.cxx b/src/InputStream.cxx index 23e535d15..52eef2caf 100644 --- a/src/InputStream.cxx +++ b/src/InputStream.cxx @@ -39,21 +39,21 @@ input_stream::Open(const char *url, struct input_stream *is; is = plugin->open(url, mutex, cond, error); - if (is != NULL) { - assert(is->plugin.close != NULL); - assert(is->plugin.read != NULL); - assert(is->plugin.eof != NULL); - assert(!is->seekable || is->plugin.seek != NULL); + if (is != nullptr) { + assert(is->plugin.close != nullptr); + assert(is->plugin.read != nullptr); + assert(is->plugin.eof != nullptr); + assert(!is->seekable || is->plugin.seek != nullptr); is = input_rewind_open(is); return is; } else if (error.IsDefined()) - return NULL; + return nullptr; } error.Set(input_domain, "Unrecognized URI"); - return NULL; + return nullptr; } bool @@ -142,7 +142,7 @@ input_stream::IsAvailable() size_t input_stream::Read(void *ptr, size_t _size, Error &error) { - assert(ptr != NULL); + assert(ptr != nullptr); assert(_size > 0); return plugin.read(this, ptr, _size, error); @@ -151,7 +151,7 @@ input_stream::Read(void *ptr, size_t _size, Error &error) size_t input_stream::LockRead(void *ptr, size_t _size, Error &error) { - assert(ptr != NULL); + assert(ptr != nullptr); assert(_size > 0); const ScopeLock protect(mutex); -- cgit v1.2.3