#include #include #include #include "config.h" #include "exceptions.h" char * Estrdup(char * o) { char * r; if (!(r = strdup(o))) { exception(1, _("Out of memory.")); } return r; } void * Emalloc(size_t s) { void * r; if (!(r = malloc(s))) { exception(1, _("Out of memory.")); } return r; } void exception(int level, char *msg) { fprintf(stderr, "%s\n", msg); exit(level); }