summaryrefslogtreecommitdiffstats
path: root/crawl-ref/source/libutil.cc
diff options
context:
space:
mode:
authordshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-01-11 07:03:20 +0000
committerdshaligram <dshaligram@c06c8d41-db1a-0410-9941-cceddc491573>2007-01-11 07:03:20 +0000
commitabc565d0ca078f1d6214c447f41de3b5589155c2 (patch)
tree847a6ad3351ed7359888191b9e397cd9cedb8e67 /crawl-ref/source/libutil.cc
parent12daab03d032a6f81f739da7932ce0a0f4094b4e (diff)
downloadcrawl-ref-abc565d0ca078f1d6214c447f41de3b5589155c2.tar.gz
crawl-ref-abc565d0ca078f1d6214c447f41de3b5589155c2.zip
Changed error message + exit() sequences to end() calls so that the user can
see the error message on the console. Added docs/ to the data search path for the Windows builds. git-svn-id: https://crawl-ref.svn.sourceforge.net/svnroot/crawl-ref/trunk@829 c06c8d41-db1a-0410-9941-cceddc491573
Diffstat (limited to 'crawl-ref/source/libutil.cc')
-rw-r--r--crawl-ref/source/libutil.cc5
1 files changed, 1 insertions, 4 deletions
diff --git a/crawl-ref/source/libutil.cc b/crawl-ref/source/libutil.cc
index f59eab1ee7..5e2752de6d 100644
--- a/crawl-ref/source/libutil.cc
+++ b/crawl-ref/source/libutil.cc
@@ -416,10 +416,7 @@ int snprintf( char *str, size_t size, const char *format, ... )
char *buff = new char [ 10 * size ]; // hopefully enough
if (!buff)
- {
- fprintf(stderr, "Out of memory\n");
- exit(1);
- }
+ end(1, false, "Out of memory\n");
vsprintf( buff, format, argp );
strncpy( str, buff, size );