From eb3534e3f84c621b722b561c6c878ba6565f450d Mon Sep 17 00:00:00 2001 From: jtvolpe Date: Sun, 4 Feb 2001 20:58:58 +0000 Subject: [PATCH] Wrong case on file SDCCerr.c git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@580 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- support/Util/{sdccerr.c => SDCCerr.c} | 37 +++++++++++++++++---------- 1 file changed, 24 insertions(+), 13 deletions(-) rename support/Util/{sdccerr.c => SDCCerr.c} (92%) diff --git a/support/Util/sdccerr.c b/support/Util/SDCCerr.c similarity index 92% rename from support/Util/sdccerr.c rename to support/Util/SDCCerr.c index 4507bb61..25f772e6 100644 --- a/support/Util/sdccerr.c +++ b/support/Util/SDCCerr.c @@ -1,27 +1,35 @@ /* -=============================================================================== -ERROR - Standard error handler - - -=============================================================================== -*/ + * SDCCerr - Standard error handler + * + * 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 Library 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. + */ #include -#include "sdccerr.h" +#include "SDCCerr.h" #define USE_STDOUT_FOR_ERRORS 0 #if USE_STDOUT_FOR_ERRORS - -static FILE *ErrorOut = stdout ; - +#define DEFAULT_ERROR_OUT stdout #else - -static FILE *ErrorOut = stderr ; - +#define DEFAULT_ERROR_OUT stderr #endif +static FILE *ErrorOut ; + #define ERROR 0 #define WARNING 1 @@ -196,6 +204,9 @@ vwerror - Output a standard eror message with variable number of arguements void vwerror (int errNum, va_list marker) { +if (!ErrorOut) + ErrorOut = DEFAULT_ERROR_OUT ; + if ( ErrTab[errNum].errType == ERROR ) fatalError++ ; -- 2.47.2