fix reversed in/out file closing when an error occurs. From Ken Pettit

This commit is contained in:
Gregory Nutt 2014-10-03 11:22:37 -06:00
parent c40e173036
commit 79169c711f

View File

@ -621,10 +621,10 @@ int cmd_dd(FAR struct nsh_vtbl_s *vtbl, int argc, char **argv)
ret = OK;
errout_with_outf:
DD_INCLOSE(&dd);
DD_OUTCLOSE(&dd);
errout_with_inf:
DD_OUTCLOSE(&dd);
DD_INCLOSE(&dd);
free(dd.buffer);
errout_with_paths: