Apply code review feedback to client refactor
- Rename phase_time to step_time for consistency with Step enum - Unify blob_size and file_size into single blob_size field - Merge toastyfs_alloc into toastyfs_init, returning malloced ToastyFS* - Replace (MessageHeader*)&msg casts with &msg.base - Replace !resp.size with explicit resp.size == 0 https://claude.ai/code/session_018MRQTdAZoBCXJZgdP4U6V6
This commit is contained in:
+2
-5
@@ -39,12 +39,9 @@ int random_client_init(void *state_, int argc, char **argv,
|
||||
}
|
||||
}
|
||||
|
||||
state->tfs = toastyfs_alloc();
|
||||
if (state->tfs == NULL)
|
||||
return -1;
|
||||
|
||||
uint64_t client_id = next_random_client_id++;
|
||||
if (toastyfs_init(state->tfs, client_id, addrs, num_addrs) < 0)
|
||||
state->tfs = toastyfs_init(client_id, addrs, num_addrs);
|
||||
if (state->tfs == NULL)
|
||||
return -1;
|
||||
|
||||
*timeout = 0;
|
||||
|
||||
Reference in New Issue
Block a user