Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions src/brpc/event_dispatcher.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ static void StopAndJoinGlobalDispatchers() {
delete g_edisp_read_lantency;
delete g_edisp_write_lantency;
}

void InitializeGlobalDispatchers() {
g_edisp_read_lantency = new bvar::LatencyRecorder("event_dispatcher_read_latency");
g_edisp_write_lantency = new bvar::LatencyRecorder("event_dispatcher_write_latency");
Expand Down
2 changes: 1 addition & 1 deletion src/bthread/parking_lot.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,10 @@ class BAIDU_CACHELINE_ALIGNMENT ParkingLot {
// Wake up at most `num_task' workers.
// Returns #workers woken up.
int signal(int num_task) {
_pending_signal.fetch_add((num_task << 1), butil::memory_order_release);
if (_waiter_num.load(butil::memory_order_relaxed) == 0) {
return 0;
}
_pending_signal.fetch_add((num_task << 1), butil::memory_order_release);
return futex_wake_private(&_pending_signal, num_task);
}

Expand Down
2 changes: 1 addition & 1 deletion src/butil/file_util_posix.cc
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ bool CreateDirectoryAndGetError(const FilePath& full_path,
if (mkdir(i->value().c_str(), 0755/*others can read the dir*/) == 0)
continue;
// Mkdir failed, but it might have failed with EEXIST, or some other error
// due to the the directory appearing out of thin air. This can occur if
// due to the directory appearing out of thin air. This can occur if
// two processes are trying to create the same file system tree at the same
// time. Check to see if it exists and make sure it is a directory.
int saved_errno = errno;
Expand Down
Loading