]> sjero.net Git - wget/blobdiff - src/xmalloc.h
Merging my botched import with Alex's original commit.
[wget] / src / xmalloc.h
index bac53cb9da2aae5b7df84fe5acb0daf58a26d4eb..ce326b1b7ae9300390cafd6b1d24783fbf1a3024 100644 (file)
@@ -1,5 +1,5 @@
 /* xmalloc.c declarations.
-   Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation,
+   Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation,
    Inc.
 
 This file is part of GNU Wget.
@@ -31,6 +31,13 @@ as that of the covered work.  */
 #ifndef XMALLOC_H
 #define XMALLOC_H
 
+/* Croak the fatal memory error and bail out with non-zero exit
+   status.  */
+void memfatal (const char *context, long attempted_size);
+
+/* Constant is using when we don`t know attempted size exactly */
+#define UNKNOWN_ATTEMPTED_SIZE -3
+
 /* Define this to use Wget's builtin malloc debugging, which is crude
    but occasionally useful.  It will make Wget a lot slower and
    larger, and susceptible to aborting if malloc_table overflows, so