File: crm_util_errorhandlers.c

package info (click to toggle)
crm114 20100106-10
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye
  • size: 3,184 kB
  • sloc: ansic: 34,910; sh: 617; makefile: 578; lisp: 208
file content (43 lines) | stat: -rw-r--r-- 1,205 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//	crm_util_errorhandlers.c - Error handling routines to be used ONLY
//	in utilities, not in the CRM114 engine itself; these don't do
//	what you need for the full crm114 runtime.

// Copyright 2009 William S. Yerazunis.
// This file is under GPLv3, as described in COPYING.

#include <stdio.h>
#include <stdlib.h>

long fatalerror ( char *str1, char *str2)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}
long nonfatalerror ( char *str1, char *str2)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}
long untrappableerror ( char *str1, char *str2)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}
long fatalerror5 ( char *str1, char *str2,
                   char *filename, char *function, unsigned lineno)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}
long nonfatalerror5 ( char *str1, char *str2,
                      char *filename, char *function, unsigned lineno)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}
long untrappableerror5 ( char *str1, char *str2,
                         char *filename, char *function, unsigned lineno)
{
  fprintf (stderr, "ERROR: %s%s \n", str1, str2);
  exit (-1);
}