2 Copyright © 1995-2001, The AROS Development Team. All rights reserved.
9 /******************************************************************************
24 Print additional information why an operation failed. Ordinarily
25 when a command fails a brief message is printed that typically
26 includes the name of the command that failed but provides few
27 details. Why fills in details related to the failed operation.
45 ******************************************************************************/
49 #include <proto/exec.h>
50 #include <proto/dos.h>
52 #include <dos/dosextens.h>
54 #include <aros/shcommands.h>
60 struct CommandLineInterface
*cli
;
62 int error
= RETURN_OK
;
65 if ((cli
= Cli()) != NULL
)
67 lasterror
= cli
->cli_Result2
;
69 if (cli
->cli_ReturnCode
== 0 || lasterror
== 0)
71 VPrintf("The last command did not set a return-value\n", NULL
);
75 PrintFault(lasterror
, "The last command failed, reason");