Update of /cvsroot/blob/blob/include
In directory usw-pr-cvs1:/tmp/cvs-serv4842/include
Modified Files:
errno.h error.h Makefile.am
Log Message:
Generalised error handling functions
Index: errno.h
===================================================================
RCS file: /cvsroot/blob/blob/include/errno.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- errno.h 2001/10/03 16:01:25 1.1
+++ errno.h 2001/10/03 16:02:43 1.2
@@ -0,0 +1,42 @@
+/*
+ * errno.h: error numbers for blob
+ *
+ * Copyright (C) 2001 Erik Mouw (J.A...@it...)
+ *
+ * $Id$
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#ident "$Id$"
+
+#ifndef BLOB_ERRNO_H
+#define BLOB_ERRNO_H
+
+
+#define ENOERROR 0 /* no error at all */
+#define EINVAL 1 /* invalid argument */
+#define ENOPARAMS 2 /* not enough parameters */
+#define EMAGIC 3 /* magic value failed */
+#define ECOMMAND 4 /* invalid command */
+#define ENAN 5 /* not a number */
+#define EALIGN 6 /* addres not aligned */
+#define ERANGE 7 /* out of range */
+#define ETIMEOUT 8 /* timeout exceeded */
+#define ETOOSHORT 9 /* short file */
+#define ETOOLONG 10 /* long file */
+
+#endif
Index: error.h
===================================================================
RCS file: /cvsroot/blob/blob/include/error.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- error.h 2001/10/03 16:01:25 1.1
+++ error.h 2001/10/03 16:02:43 1.2
@@ -0,0 +1,35 @@
+/*
+ * error.h: error handling functions
+ *
+ * Copyright (C) 2001 Erik Mouw (J.A...@it...)
+ *
+ * $Id$
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ *
+ */
+
+#ident "$Id$"
+
+#ifndef BLOB_ERROR_H
+#define BLOB_ERROR_H
+
+
+char *strerror(int errnum);
+void printerrprefix(void);
+void printerror(int errnum, char *s);
+
+
+#endif
Index: Makefile.am
===================================================================
RCS file: /cvsroot/blob/blob/include/Makefile.am,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- Makefile.am 2001/10/02 21:39:54 1.5
+++ Makefile.am 2001/10/03 16:02:43 1.6
@@ -13,6 +13,8 @@
noinst_HEADERS = \
command.h \
+ errno.h \
+ error.h \
flash.h \
init.h \
led.h \
|