Skip to content

Commit eb05adb

Browse files
committed
formatting
Signed-off-by: Rob Johnson <rob@robjohnson.io>
1 parent 24eae2d commit eb05adb

2 files changed

Lines changed: 30 additions & 29 deletions

File tree

src/core.c

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@ core_checkpoint_lock_init(core_handle *spl)
5959
rc = platform_mutex_init(
6060
&spl->checkpoint_state_lock, platform_get_module_id(), spl->heap_id);
6161
if (!SUCCESS(rc)) {
62-
platform_status destroy_rc = platform_mutex_destroy(&spl->checkpoint_lock);
62+
platform_status destroy_rc =
63+
platform_mutex_destroy(&spl->checkpoint_lock);
6364
platform_assert_status_ok(destroy_rc);
6465
return rc;
6566
}
@@ -2412,10 +2413,10 @@ core_mount(core_handle *spl,
24122413
* silently reverting to this now-stale root. The root is unchanged; a clean
24132414
* mount has no prior live log, so the sealed slot stays empty.
24142415
*/
2415-
superblock_log_cut(
2416-
&spl->superblock,
2417-
spl->cfg.use_log ? core_log_to_superblock(log_get_head(spl->log))
2418-
: (superblock_log_head){0});
2416+
superblock_log_cut(&spl->superblock,
2417+
spl->cfg.use_log
2418+
? core_log_to_superblock(log_get_head(spl->log))
2419+
: (superblock_log_head){0});
24192420
rc = superblock_make_durable(&spl->superblock);
24202421
if (!SUCCESS(rc)) {
24212422
platform_error_log("core_mount: mark-dirty superblock_make_durable "
@@ -2567,7 +2568,7 @@ core_checkpoint(core_handle *spl)
25672568
{
25682569
platform_status rc;
25692570
superblock_log_head new_live = {0};
2570-
log_head sealed = {0};
2571+
log_head sealed = {0};
25712572

25722573
if (spl->cfg.use_log) {
25732574
// --- Begin: seal the live log, start a fresh one, and publish

tests/functional/log_test.c

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -35,16 +35,16 @@ test_log_crash(clockcache *cc,
3535
bool32 crash)
3636

3737
{
38-
platform_status rc;
39-
log_handle *logh;
40-
uint64 i;
41-
key returned_key;
42-
message returned_message;
43-
log_head segment;
44-
log_iterator *itor;
45-
char key_str[128];
46-
char data_str[128];
47-
merge_accumulator msg;
38+
platform_status rc;
39+
log_handle *logh;
40+
uint64 i;
41+
key returned_key;
42+
message returned_message;
43+
log_head segment;
44+
log_iterator *itor;
45+
char key_str[128];
46+
char data_str[128];
47+
merge_accumulator msg;
4848
DECLARE_AUTO_KEY_BUFFER(keybuffer, hid);
4949

5050
platform_assert(cc != NULL);
@@ -178,7 +178,7 @@ test_log_write_range(log_handle *logh,
178178
static void
179179
test_log_verify_segment(cache *cc,
180180
shard_log_config *cfg,
181-
const log_head *segment,
181+
const log_head *segment,
182182
test_message_generator *gen,
183183
platform_heap_id hid,
184184
uint64 key_size,
@@ -244,9 +244,9 @@ test_log_two_segments(clockcache *cc,
244244
test_message_generator *gen,
245245
uint64 key_size)
246246
{
247-
const uint64 old_first = 1000, old_count = 16;
248-
const uint64 new_first = 2000, new_count = 16;
249-
log_head sealed, fresh;
247+
const uint64 old_first = 1000, old_count = 16;
248+
const uint64 new_first = 2000, new_count = 16;
249+
log_head sealed, fresh;
250250

251251
log_handle *log = shard_log_create((cache *)cc, cfg, hid);
252252
platform_assert(log != NULL);
@@ -304,15 +304,15 @@ test_log_two_segments(clockcache *cc,
304304
static int
305305
test_log_large_message(cache *cc, shard_log_config *cfg, platform_heap_id hid)
306306
{
307-
platform_status rc;
308-
log_head sealed;
309-
log_iterator *itor;
310-
merge_accumulator msg;
311-
key returned_key;
312-
message returned_message;
313-
char key_data[] = "large-log-key";
314-
key skey = key_create(FALSE, sizeof(key_data) - 1, key_data);
315-
uint64 value_len = 3 * cache_page_size(cc) + 123;
307+
platform_status rc;
308+
log_head sealed;
309+
log_iterator *itor;
310+
merge_accumulator msg;
311+
key returned_key;
312+
message returned_message;
313+
char key_data[] = "large-log-key";
314+
key skey = key_create(FALSE, sizeof(key_data) - 1, key_data);
315+
uint64 value_len = 3 * cache_page_size(cc) + 123;
316316

317317
log_handle *logh = shard_log_create(cc, cfg, hid);
318318
platform_assert(logh != NULL);

0 commit comments

Comments
 (0)