diff options
author | Andreas Schneider <asn@samba.org> | 2014-02-17 10:47:15 +0100 |
---|---|---|
committer | Andreas Schneider <asn@samba.org> | 2014-02-19 18:22:29 +0100 |
commit | a65f557c6b588b725d1e4900f1a0bf5772d9c892 (patch) | |
tree | 24ec68a4e0ace9e6018a722443c5356a42179818 /source3 | |
parent | 3707fba088873988427875c60ae379dc6e218eda (diff) | |
download | samba-a65f557c6b588b725d1e4900f1a0bf5772d9c892.tar.gz |
s3-clitar: Improve readabilty of cmd_block().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
Diffstat (limited to 'source3')
-rw-r--r-- | source3/client/clitar.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/source3/client/clitar.c b/source3/client/clitar.c index b8bdbdd1b92..12a5e0d5cc2 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>\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; |