Skip to content

Commit

Permalink
Fix bitops.c clang-format properly (#570)
Browse files Browse the repository at this point in the history
ref:
- #118 (my pervious change)
- #461 (issuing that clang
format checker fails due to my change)

There was an issue that clang-format cheker failed.
I don't know why I missed it and why it didn't catch.

just running `clang-format -i bitops.c` was all.

Signed-off-by: LiiNen <kjeonghoon065@gmail.com>
  • Loading branch information
LiiNen authored May 29, 2024
1 parent 96dcd11 commit 168da8b
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/bitops.c
Original file line number Diff line number Diff line change
Expand Up @@ -808,10 +808,9 @@ void bitcountCommand(client *c) {
}
}
if (c->argc >= 4) {
if (getLongLongFromObjectOrReply(c,c->argv[3],&end,NULL) != C_OK)
return;
if (getLongLongFromObjectOrReply(c, c->argv[3], &end, NULL) != C_OK) return;
}

/* Lookup, check for type. */
o = lookupKeyRead(c->db, c->argv[1]);
if (checkType(c, o, OBJ_STRING)) return;
Expand All @@ -821,7 +820,7 @@ void bitcountCommand(client *c) {
/* Make sure we will not overflow */
serverAssert(totlen <= LLONG_MAX >> 3);

if (c->argc < 4) end = totlen-1;
if (c->argc < 4) end = totlen - 1;

/* Convert negative indexes */
if (start < 0 && end < 0 && start > end) {
Expand Down

0 comments on commit 168da8b

Please sign in to comment.