From a65f557c6b588b725d1e4900f1a0bf5772d9c892 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 17 Feb 2014 10:47:15 +0100 Subject: s3-clitar: Improve readabilty of cmd_block(). Signed-off-by: Andreas Schneider Reviewed-by: David Disseldorp --- source3/client/clitar.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'source3') diff --git a/source3/client/clitar.c b/source3/client/clitar.c index b8bdbdd1b9..12a5e0d5cc 100644 --- a/source3/client/clitar.c +++ b/source3/client/clitar.c @@ -250,14 +250,17 @@ int cmd_block(void) char *buf; TALLOC_CTX *ctx = PANIC_IF_NULL(talloc_new(NULL)); int err = 0; + bool ok; - if (!next_token_talloc(ctx, &cmd_ptr, &buf, NULL)) { + ok = next_token_talloc(ctx, &cmd_ptr, &buf, NULL); + if (!ok) { DBG(0, ("blocksize \n")); err = 1; goto out; } - if (tar_set_blocksize(&tar_ctx, atoi(buf))) { + ok = tar_set_blocksize(&tar_ctx, atoi(buf)); + if (ok) { DBG(0, ("invalid blocksize\n")); err = 1; goto out; -- cgit