Skip to content

Commit

Permalink
src: lint node_win32_perfctr_provider.cc
Browse files Browse the repository at this point in the history
PR-URL: #7462
Reviewed-By: Trevor Norris <trev.norris@gmail.com>
  • Loading branch information
bnoordhuis authored and Myles Borins committed Jul 14, 2016
1 parent 0db3aa9 commit 27c2d25
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 11 deletions.
1 change: 0 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -638,7 +638,6 @@ CPPLINT_EXCLUDE ?=
CPPLINT_EXCLUDE += src/node_lttng.cc
CPPLINT_EXCLUDE += src/node_root_certs.h
CPPLINT_EXCLUDE += src/node_lttng_tp.h
CPPLINT_EXCLUDE += src/node_win32_perfctr_provider.cc
CPPLINT_EXCLUDE += src/queue.h
CPPLINT_EXCLUDE += src/tree.h
CPPLINT_EXCLUDE += src/v8abbr.h
Expand Down
30 changes: 20 additions & 10 deletions src/node_win32_perfctr_provider.cc
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,8 @@ void TermPerfCountersWin32() {


void NODE_COUNT_HTTP_SERVER_REQUEST() {
if (NodeCounterProvider != nullptr && perfctr_incrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongValue != nullptr) {
perfctr_incrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_HTTP_SERVER_REQUEST,
Expand All @@ -203,7 +204,8 @@ void NODE_COUNT_HTTP_SERVER_REQUEST() {


void NODE_COUNT_HTTP_SERVER_RESPONSE() {
if (NodeCounterProvider != nullptr && perfctr_incrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongValue != nullptr) {
perfctr_incrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_HTTP_SERVER_RESPONSE,
Expand All @@ -213,7 +215,8 @@ void NODE_COUNT_HTTP_SERVER_RESPONSE() {


void NODE_COUNT_HTTP_CLIENT_REQUEST() {
if (NodeCounterProvider != nullptr && perfctr_incrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongValue != nullptr) {
perfctr_incrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_HTTP_CLIENT_REQUEST,
Expand All @@ -223,7 +226,8 @@ void NODE_COUNT_HTTP_CLIENT_REQUEST() {


void NODE_COUNT_HTTP_CLIENT_RESPONSE() {
if (NodeCounterProvider != nullptr && perfctr_incrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongValue != nullptr) {
perfctr_incrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_HTTP_CLIENT_RESPONSE,
Expand All @@ -233,7 +237,8 @@ void NODE_COUNT_HTTP_CLIENT_RESPONSE() {


void NODE_COUNT_SERVER_CONN_OPEN() {
if (NodeCounterProvider != nullptr && perfctr_incrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongValue != nullptr) {
perfctr_incrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_SERVER_CONNS,
Expand All @@ -243,7 +248,8 @@ void NODE_COUNT_SERVER_CONN_OPEN() {


void NODE_COUNT_SERVER_CONN_CLOSE() {
if (NodeCounterProvider != nullptr && perfctr_decrementULongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_decrementULongValue != nullptr) {
perfctr_decrementULongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_SERVER_CONNS,
Expand All @@ -253,7 +259,8 @@ void NODE_COUNT_SERVER_CONN_CLOSE() {


void NODE_COUNT_NET_BYTES_SENT(int bytes) {
if (NodeCounterProvider != nullptr && perfctr_incrementULongLongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongLongValue != nullptr) {
perfctr_incrementULongLongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_NET_BYTES_SENT,
Expand All @@ -263,7 +270,8 @@ void NODE_COUNT_NET_BYTES_SENT(int bytes) {


void NODE_COUNT_NET_BYTES_RECV(int bytes) {
if (NodeCounterProvider != nullptr && perfctr_incrementULongLongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongLongValue != nullptr) {
perfctr_incrementULongLongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_NET_BYTES_RECV,
Expand Down Expand Up @@ -293,7 +301,8 @@ void NODE_COUNT_GC_PERCENTTIME(unsigned int percent) {


void NODE_COUNT_PIPE_BYTES_SENT(int bytes) {
if (NodeCounterProvider != nullptr && perfctr_incrementULongLongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongLongValue != nullptr) {
perfctr_incrementULongLongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_PIPE_BYTES_SENT,
Expand All @@ -303,7 +312,8 @@ void NODE_COUNT_PIPE_BYTES_SENT(int bytes) {


void NODE_COUNT_PIPE_BYTES_RECV(int bytes) {
if (NodeCounterProvider != nullptr && perfctr_incrementULongLongValue != nullptr) {
if (NodeCounterProvider != nullptr &&
perfctr_incrementULongLongValue != nullptr) {
perfctr_incrementULongLongValue(NodeCounterProvider,
perfctr_instance,
NODE_COUNTER_PIPE_BYTES_RECV,
Expand Down

0 comments on commit 27c2d25

Please sign in to comment.