/[ascend]/trunk/base/generic/utilities/error.c
ViewVC logotype

Diff of /trunk/base/generic/utilities/error.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 156 by johnpye, Tue Dec 20 14:34:32 2005 UTC revision 157 by johnpye, Fri Dec 23 01:30:46 2005 UTC
# Line 15  Line 15 
15  */  */
16  #  define ERR_RED "\033[31;1m"  #  define ERR_RED "\033[31;1m"
17  #  define ERR_GRN "\033[32;2m"  #  define ERR_GRN "\033[32;2m"
18    #  define ERR_BLU "\033[34;1m"
19    #  define ERR_BRN "\033[33;1m"
20  #  define ERR_NORM "\033[0m"  #  define ERR_NORM "\033[0m"
21  #else  #else
22  #  define ERR_RED ""  #  define ERR_RED ""
23  #  define ERR_GRN ""  #  define ERR_GRN ""
24    #  define ERR_BLU ""
25    #  define ERR_BRN ""
26  #  define ERR_NORM ""  #  define ERR_NORM ""
27  #endif  #endif
28    
# Line 47  int error_reporter_default_callback(ERRO Line 51  int error_reporter_default_callback(ERRO
51          case ASC_PROG_ERROR:    sevmsg = ERR_RED "PROGRAM ERROR: " ERR_NORM; break;          case ASC_PROG_ERROR:    sevmsg = ERR_RED "PROGRAM ERROR: " ERR_NORM; break;
52          case ASC_PROG_WARNING:  sevmsg = "PROGRAM WARNING: "; break;          case ASC_PROG_WARNING:  sevmsg = "PROGRAM WARNING: "; break;
53          case ASC_PROG_NOTE:     sevmsg = ERR_GRN; endtxt=ERR_NORM; break; /* default, keep unembellished for now */          case ASC_PROG_NOTE:     sevmsg = ERR_GRN; endtxt=ERR_NORM; break; /* default, keep unembellished for now */
54          case ASC_USER_ERROR:    sevmsg = "ERROR: "; break;          case ASC_USER_ERROR:    sevmsg = ERR_RED "ERROR: " ERR_NORM; break;
55          case ASC_USER_WARNING:  sevmsg = "WARNING: "; break;          case ASC_USER_WARNING:  sevmsg = ERR_BRN "WARNING: " ERR_NORM; break;
56          case ASC_USER_NOTE:     sevmsg = "NOTE: "; break;          case ASC_USER_NOTE:     sevmsg = "NOTE: "; break;
57          case ASC_USER_SUCCESS:  sevmsg = "SUCCESS: "; break;          case ASC_USER_SUCCESS:  sevmsg = ERR_GRN "SUCCESS: " ERR_NORM; break;
58      }      }
59            
60      res = ASC_FPRINTF(ASCERR,sevmsg);      res = ASC_FPRINTF(ASCERR,sevmsg);

Legend:
Removed from v.156  
changed lines
  Added in v.157

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22