Replace NULL with nullptr or null in webrtc/base/.
BUG=webrtc:7147 Review-Url: https://codereview.webrtc.org/2718663005 Cr-Commit-Position: refs/heads/master@{#16878}
This commit is contained in:
@ -56,7 +56,7 @@ class ThreadManager {
|
||||
// unexpected contexts (like inside browser plugins) and it would be a
|
||||
// shame to break it. It is also conceivable on Win32 that we won't even
|
||||
// be able to get synchronization privileges, in which case the result
|
||||
// will have a NULL handle.
|
||||
// will have a null handle.
|
||||
Thread *WrapCurrentThread();
|
||||
void UnwrapCurrentThread();
|
||||
|
||||
@ -133,12 +133,12 @@ class LOCKABLE Thread : public MessageQueue {
|
||||
static bool SleepMs(int millis);
|
||||
|
||||
// Sets the thread's name, for debugging. Must be called before Start().
|
||||
// If |obj| is non-NULL, its value is appended to |name|.
|
||||
// If |obj| is non-null, its value is appended to |name|.
|
||||
const std::string& name() const { return name_; }
|
||||
bool SetName(const std::string& name, const void* obj);
|
||||
|
||||
// Starts the execution of the thread.
|
||||
bool Start(Runnable* runnable = NULL);
|
||||
bool Start(Runnable* runnable = nullptr);
|
||||
|
||||
// Tells the thread to stop and waits until it is joined.
|
||||
// Never call Stop on the current thread. Instead use the inherited Quit
|
||||
@ -154,7 +154,7 @@ class LOCKABLE Thread : public MessageQueue {
|
||||
virtual void Send(const Location& posted_from,
|
||||
MessageHandler* phandler,
|
||||
uint32_t id = 0,
|
||||
MessageData* pdata = NULL);
|
||||
MessageData* pdata = nullptr);
|
||||
|
||||
// Convenience method to invoke a functor on another thread. Caller must
|
||||
// provide the |ReturnT| template argument, which cannot (easily) be deduced.
|
||||
@ -174,7 +174,7 @@ class LOCKABLE Thread : public MessageQueue {
|
||||
// From MessageQueue
|
||||
void Clear(MessageHandler* phandler,
|
||||
uint32_t id = MQID_ANY,
|
||||
MessageList* removed = NULL) override;
|
||||
MessageList* removed = nullptr) override;
|
||||
void ReceiveSends() override;
|
||||
|
||||
// ProcessMessages will process I/O and dispatch messages until:
|
||||
@ -255,11 +255,11 @@ class LOCKABLE Thread : public MessageQueue {
|
||||
// Return true if the thread was started and hasn't yet stopped.
|
||||
bool running() { return running_.Wait(0); }
|
||||
|
||||
// Processes received "Send" requests. If |source| is not NULL, only requests
|
||||
// Processes received "Send" requests. If |source| is not null, only requests
|
||||
// from |source| are processed, otherwise, all requests are processed.
|
||||
void ReceiveSendsFromThread(const Thread* source);
|
||||
|
||||
// If |source| is not NULL, pops the first "Send" message from |source| in
|
||||
// If |source| is not null, pops the first "Send" message from |source| in
|
||||
// |sendlist_|, otherwise, pops the first "Send" message of |sendlist_|.
|
||||
// The caller must lock |crit_| before calling.
|
||||
// Returns true if there is such a message.
|
||||
|
||||
Reference in New Issue
Block a user