simplifying logic in upcall_marshall

This commit is contained in:
Olga Kornievskaia 2011-08-24 17:07:45 -04:00
parent 912f6ae500
commit 9765eb7d52

View file

@ -159,7 +159,6 @@ void upcall_marshall(
IN uint32_t length, IN uint32_t length,
OUT uint32_t *length_out) OUT uint32_t *length_out)
{ {
int status = NO_ERROR;
const nfs41_upcall_op *op; const nfs41_upcall_op *op;
unsigned char *orig_buf = buffer; unsigned char *orig_buf = buffer;
const uint32_t total = length, orig_len = length; const uint32_t total = length, orig_len = length;
@ -179,11 +178,8 @@ write_downcall:
/* marshall the operation's results */ /* marshall the operation's results */
op = g_upcall_op_table[upcall->opcode]; op = g_upcall_op_table[upcall->opcode];
if (op && op->marshall) { if (op && op->marshall) {
status = op->marshall(buffer, &length, upcall); if ((upcall->status = op->marshall(buffer, &length, upcall)))
if (status) {
upcall->status = status;
goto write_downcall; goto write_downcall;
}
} }
out: out:
*length_out = total - length; *length_out = total - length;