Skip to content

Commit

Permalink
Rename BRPC_VALIDATE_GFLAG to BUTIL_VALIDATE_GFLAG
Browse files Browse the repository at this point in the history
  • Loading branch information
chenBright committed Dec 20, 2024
1 parent 4b4a974 commit 298898f
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 2 additions & 0 deletions src/brpc/reloadable_flags.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@

#include "butil/reloadable_flags.h"

#define BRPC_VALIDATE_GFLAG(flag, validate_fn) BUTIL_VALIDATE_GFLAG(flag, validate_fn)

namespace brpc {

extern bool PassValidate(const char*, bool);
Expand Down
2 changes: 0 additions & 2 deletions src/bthread/bthread.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@
#include "bthread/id.h"

#if defined(__cplusplus) && defined(BRPC_BTHREAD_TRACER)
#include "butil/resource_pool.h"
#include "bthread/task_meta.h"
namespace bthread {
// Assign a TaskMeta to the pthread and set the state to Running,
// so that `stack_trace()' can trace the call stack of the pthread.
Expand Down
2 changes: 1 addition & 1 deletion src/bthread/task_tracer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ namespace bthread {

DEFINE_bool(enable_fast_unwind, true, "Whether to enable fast unwind");
DEFINE_uint32(signal_trace_timeout_ms, 50, "Timeout for signal trace in ms");
BRPC_VALIDATE_GFLAG(signal_trace_timeout_ms, butil::PositiveInteger<uint32_t>);
BUTIL_VALIDATE_GFLAG(signal_trace_timeout_ms, butil::PositiveInteger<uint32_t>);

extern BAIDU_THREAD_LOCAL TaskMeta* pthread_fake_meta;

Expand Down
2 changes: 1 addition & 1 deletion src/butil/reloadable_flags.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
// This macro does not work for string-flags because they're thread-unsafe to
// modify directly. To emphasize this, you have to write the validator by
// yourself and use GFLAGS_NS::GetCommandLineOption() to acess the flag.
#define BRPC_VALIDATE_GFLAG(flag, validate_fn) \
#define BUTIL_VALIDATE_GFLAG(flag, validate_fn) \
namespace butil_flags {} \
const int register_FLAGS_ ## flag ## _dummy \
__attribute__((__unused__)) = \
Expand Down
2 changes: 1 addition & 1 deletion src/butil/time.h
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ class Timer {
};

Timer() : _stop(0), _start(0) {}
explicit Timer(const TimerType) {
explicit Timer(const TimerType) : Timer() {
start();
}

Expand Down

0 comments on commit 298898f

Please sign in to comment.