summaryrefslogtreecommitdiff
path: root/avr/strerror.c
diff options
context:
space:
mode:
Diffstat (limited to 'avr/strerror.c')
-rw-r--r--avr/strerror.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/avr/strerror.c b/avr/strerror.c
index d80a3bc..bb151ad 100644
--- a/avr/strerror.c
+++ b/avr/strerror.c
@@ -5,20 +5,22 @@
*/
#include "common.h"
+#include "errnum.h"
#include "cmd_fat.h"
+
static const FLASH char * const FLASH error_strings[] = {
- FSTR("Unknown error")
+ FSTR("Unknown error"),
+ FSTR("Not enough memory"),
+ FSTR("Bus timeout")
};
-const FLASH char * my_strerror_P(int errnum)
+const FLASH char * my_strerror_P(ERRNUM errnum)
{
if (errnum < 100)
return fat_rctostr(errnum);
errnum -= 100;
- if (errnum < 0)
- errnum = 0;
if ((unsigned) errnum >= ARRAY_SIZE(error_strings))
errnum = 0;